@@ -423,15 +423,15 @@ type STLResult struct {
func execStlPythonCode(path, toPath string, period, seasonal, trend, trendDeg, seasonalDeg, lowPassDeg int, fraction float64, robust bool) (stlResult *STLResult, err error) {
pythonCode := `
+import json
+import warnings
+warnings.filterwarnings('ignore')
import pandas as pd
from statsmodels.tsa.seasonal import STL
from statsmodels.nonparametric.smoothers_lowess import lowess
from statsmodels.tsa.stattools import adfuller
from statsmodels.stats.diagnostic import acorr_ljungbox
import numpy as np
-import json
-import warnings
-warnings.filterwarnings('ignore')
file_path = r"%s"
df = pd.read_excel(file_path, parse_dates=['日期'], engine='openpyxl')