freq-staticgrid-base
This commit is contained in:
parent
de1601d9ff
commit
a44179cc1d
@ -69,6 +69,12 @@ START_DATE_RAW=""
|
||||
END_DATE_RAW=""
|
||||
PAIRS_ARG=""
|
||||
PAIR_REMOTE_LIST_URL=""
|
||||
STRATEGY_ARG=""
|
||||
CONFIG_ARG=""
|
||||
|
||||
# 先从 .env 加载默认值
|
||||
STRATEGY_NAME=${STRATEGY_NAME:-FreqaiPrimer}
|
||||
CONFIG_FILE=${CONFIG_FILE:-basic.json}
|
||||
|
||||
# Parse parameters based on whether we have named parameters
|
||||
if [ "$HAS_NAMED_PARAMS" = true ]; then
|
||||
@ -233,8 +239,13 @@ fi
|
||||
# 检查指定的配置文件是否存在,如果不存在则使用默认配置
|
||||
echo "Checking config file: freqtrade/templates/$CONFIG_FILE"
|
||||
if [ ! -f "../freqtrade/templates/$CONFIG_FILE" ]; then
|
||||
echo "Warning: Config file freqtrade/templates/$CONFIG_FILE not found, using default configuration"
|
||||
CONFIG_FILE="basic.json"
|
||||
# 如果在 templates 中找不到,尝试在 config_examples 中找
|
||||
if [ ! -f "../config_examples/$CONFIG_FILE" ]; then
|
||||
echo "Warning: Config file freqtrade/templates/$CONFIG_FILE not found, using default configuration"
|
||||
CONFIG_FILE="basic.json"
|
||||
else
|
||||
echo "Config file found: config_examples/$CONFIG_FILE"
|
||||
fi
|
||||
else
|
||||
echo "Config file found: freqtrade/templates/$CONFIG_FILE"
|
||||
fi
|
||||
@ -269,7 +280,7 @@ echo "docker-compose run --rm freqtrade backtesting $PAIRS_FLAG \
|
||||
--freqaimodel LightGBMRegressorMultiTarget \
|
||||
--config /freqtrade/config_examples/$CONFIG_FILE \
|
||||
--config /freqtrade/templates/$CONFIG_FILE \
|
||||
--strategy $STRATEGY_NAME \
|
||||
--strategy $STRATEGY_NAME \
|
||||
--strategy-path /freqtrade/templates \
|
||||
--timerange $START_DATE-$END_DATE \
|
||||
--fee 0.0008 \
|
||||
@ -278,7 +289,6 @@ echo "docker-compose run --rm freqtrade backtesting $PAIRS_FLAG \
|
||||
|
||||
docker-compose run --rm freqtrade backtesting $PAIRS_FLAG \
|
||||
--logfile /freqtrade/user_data/logs/freqtrade.log \
|
||||
--freqaimodel LightGBMRegressorMultiTarget \
|
||||
--config /freqtrade/config_examples/$CONFIG_FILE \
|
||||
--config /freqtrade/templates/$CONFIG_FILE \
|
||||
--strategy $STRATEGY_CLASS_NAME \
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user