Merge pull request #7590 from freqtrade/list-models

List models
This commit is contained in:
Matthias
2022-10-17 20:40:41 +02:00
committed by GitHub
11 changed files with 120 additions and 22 deletions

View File

@@ -1,4 +1,5 @@
import logging
import sys
from pathlib import Path
from typing import Any, Dict
@@ -48,6 +49,7 @@ class CatboostClassifier(BaseClassifierModel):
init_model = self.get_init_model(dk.pair)
cbr.fit(X=train_data, eval_set=test_data, init_model=init_model)
cbr.fit(X=train_data, eval_set=test_data, init_model=init_model,
log_cout=sys.stdout, log_cerr=sys.stderr)
return cbr

View File

@@ -1,4 +1,5 @@
import logging
import sys
from pathlib import Path
from typing import Any, Dict
@@ -47,6 +48,7 @@ class CatboostRegressor(BaseRegressionModel):
**self.model_training_parameters,
)
model.fit(X=train_data, eval_set=test_data, init_model=init_model)
model.fit(X=train_data, eval_set=test_data, init_model=init_model,
log_cout=sys.stdout, log_cerr=sys.stderr)
return model

View File

@@ -1,4 +1,5 @@
import logging
import sys
from pathlib import Path
from typing import Any, Dict
@@ -58,8 +59,10 @@ class CatboostRegressorMultiTarget(BaseRegressionModel):
fit_params = []
for i in range(len(eval_sets)):
fit_params.append(
{'eval_set': eval_sets[i], 'init_model': init_models[i]})
fit_params.append({
'eval_set': eval_sets[i], 'init_model': init_models[i],
'log_cout': sys.stdout, 'log_cerr': sys.stderr,
})
model = FreqaiMultiOutputRegressor(estimator=cbr)
thread_training = self.freqai_info.get('multitarget_parallel_training', False)