Adapt hyperopt templates to be better aligned

closes #3027
This commit is contained in:
Matthias
2021-03-14 19:49:46 +01:00
parent 0b35c0571f
commit b191663a7e
3 changed files with 72 additions and 142 deletions

View File

@@ -39,6 +39,15 @@ class {{ hyperopt }}(IHyperOpt):
https://github.com/freqtrade/freqtrade/blob/develop/freqtrade/templates/sample_hyperopt_advanced.py.
"""
@staticmethod
def indicator_space() -> List[Dimension]:
"""
Define your Hyperopt space for searching buy strategy parameters.
"""
return [
{{ buy_space | indent(12) }}
]
@staticmethod
def buy_strategy_generator(params: Dict[str, Any]) -> Callable:
"""
@@ -79,12 +88,12 @@ class {{ hyperopt }}(IHyperOpt):
return populate_buy_trend
@staticmethod
def indicator_space() -> List[Dimension]:
def sell_indicator_space() -> List[Dimension]:
"""
Define your Hyperopt space for searching buy strategy parameters.
Define your Hyperopt space for searching sell strategy parameters.
"""
return [
{{ buy_space | indent(12) }}
{{ sell_space | indent(12) }}
]
@staticmethod
@@ -126,11 +135,3 @@ class {{ hyperopt }}(IHyperOpt):
return populate_sell_trend
@staticmethod
def sell_indicator_space() -> List[Dimension]:
"""
Define your Hyperopt space for searching sell strategy parameters.
"""
return [
{{ sell_space | indent(12) }}
]