Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to reduce model training time #361

Open
xiunengzy opened this issue May 24, 2022 · 4 comments
Open

How to reduce model training time #361

xiunengzy opened this issue May 24, 2022 · 4 comments
Labels

Comments

@xiunengzy
Copy link

...
model = KRG({})
model.set_training_values(inputsincolumns,outputsincolumns)
model.train()
...
#============
The amount of data:inputsincolumns(6 rows and 3000 columns),outputsincolumns(7 rows and 3000 columns)
and the trainning takes almost 5mins
Is there some way to increase training speed?

@relf
Copy link
Member

relf commented May 30, 2022

I suppose you meant 3000 rows with 6 or 7 columns as number of rows should be the same for inputs and outputs. You can try to remove some training samples and use them to validate the surrogate and see if it is good enough.

@NatOnera
Copy link
Contributor

KRG can predict only 1 output, so if you have multiple outputs you have to train a surrogate for each output.

@Paul-Saves
Copy link
Contributor

Paul-Saves commented May 30, 2022

3000 points and 7 6-D model could be long.
You could reduce Kriging option "n_start" but as the cost of decreased performances.
https://smt.readthedocs.io/en/latest/_src_docs/surrogate_models/krg.html

Another tip (not recommended);
modify Cobyla niter options in krg_based (l.1070) :
limit, _rhobeg = 15* len(self.options["theta0"]), 0.5 to
limit, _rhobeg = 5* len(self.options["theta0"]), 0.5

@Paul-Saves
Copy link
Contributor

Paul-Saves commented May 30, 2022

Ideally, it would be great to fix TNC which is a gradient-based optimizer to train continuous models much faster #294 ...

@relf relf added the question label Jun 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants