mirror of
https://github.com/freqtrade/freqtrade.git
synced 2025-11-29 00:23:07 +00:00
avoid mutating new_trained_timerange
This commit is contained in:
@@ -622,6 +622,8 @@ class IFreqaiModel(ABC):
|
|||||||
strategy, corr_dataframes, base_dataframes, pair
|
strategy, corr_dataframes, base_dataframes, pair
|
||||||
)
|
)
|
||||||
|
|
||||||
|
trained_timestamp = new_trained_timerange.stopts
|
||||||
|
|
||||||
buffered_timerange = dk.buffer_timerange(new_trained_timerange)
|
buffered_timerange = dk.buffer_timerange(new_trained_timerange)
|
||||||
|
|
||||||
unfiltered_dataframe = dk.slice_dataframe(buffered_timerange, unfiltered_dataframe)
|
unfiltered_dataframe = dk.slice_dataframe(buffered_timerange, unfiltered_dataframe)
|
||||||
@@ -632,8 +634,8 @@ class IFreqaiModel(ABC):
|
|||||||
|
|
||||||
model = self.train(unfiltered_dataframe, pair, dk)
|
model = self.train(unfiltered_dataframe, pair, dk)
|
||||||
|
|
||||||
self.dd.pair_dict[pair]["trained_timestamp"] = new_trained_timerange.stopts
|
self.dd.pair_dict[pair]["trained_timestamp"] = trained_timestamp
|
||||||
dk.set_new_model_names(pair, new_trained_timerange.stopts)
|
dk.set_new_model_names(pair, trained_timestamp)
|
||||||
self.dd.save_data(model, pair, dk)
|
self.dd.save_data(model, pair, dk)
|
||||||
|
|
||||||
if self.plot_features:
|
if self.plot_features:
|
||||||
|
|||||||
Reference in New Issue
Block a user