Allow importing interface from hyperopt.py

This commit is contained in:
Matthias
2019-07-17 07:14:27 +02:00
parent 0e500de1a0
commit 639a4d5cf7
5 changed files with 8 additions and 18 deletions

View File

@@ -8,7 +8,7 @@ from math import exp
from pandas import DataFrame
from freqtrade.optimize.hyperopt_loss_interface import IHyperOptLoss
from freqtrade.optimize.hyperopt import IHyperOptLoss
# Define some constants:

View File

@@ -21,6 +21,8 @@ from skopt.space import Dimension
from freqtrade.configuration import Arguments
from freqtrade.data.history import load_data, get_timeframe
from freqtrade.optimize.backtesting import Backtesting
# Import IHyperOptLoss to allow users import from this file
from freqtrade.optimize.hyperopt_loss_interface import IHyperOptLoss # noqa: F4
from freqtrade.resolvers.hyperopt_resolver import HyperOptResolver, HyperOptLossResolver

View File

@@ -8,7 +8,7 @@ from datetime import datetime
from pandas import DataFrame
import numpy as np
from freqtrade.optimize.hyperopt_loss_interface import IHyperOptLoss
from freqtrade.optimize.hyperopt import IHyperOptLoss
class SharpeHyperOptLoss(IHyperOptLoss):