Troubleshooting Guide¶
Installation Issues¶
ModuleNotFoundError: No module named 'sklearn'¶
Install the ML dependencies:
ModuleNotFoundError: No module named 'prophet'¶
Install the forecast dependencies:
ModuleNotFoundError: No module named 'matplotlib'¶
Install the visualisation dependencies:
XGBoost XGBoostError on macOS¶
XGBoost requires libomp (OpenMP runtime) on macOS:
ImportError: No module named 'xarray'¶
Install scientific format dependencies:
Data Collection Issues¶
ConnectionError / TimeoutError when collecting data¶
- Check your internet connection
- Some APIs may be temporarily down; try again later
- Use
--daysto limit the request size for USGS - Open-Meteo has rate limits; the built-in client handles retries automatically
Empty results from a collector¶
- taiwan_moenv: Data updates monthly; ensure the API is accessible
- usgs: Specify valid site numbers or use default (major gauges)
- openmeteo: Ensure
--lat/--lonare valid coordinates - copernicus: Requires a valid CDS API key in
~/.cdsapirc
ValueError: Unknown source¶
Check available sources:
Analysis Issues¶
ValueError: Need ≥5 years of data¶
Flood frequency analysis (GEV/LP3) requires at least 5 years of annual maxima. Collect more data or use a shorter analysis method.
ValueError: Need ≥3 complete years¶
Low-flow statistics (7Q10, 30Q5) need at least 3 complete water years. Ensure your data covers multiple years.
EDA report shows 0 parameters¶
Your data file may not have the expected schema. Ensure it contains records with parameter and value fields (for water quality) or a numeric column (for time-series).
Poor model performance (low NSE/KGE)¶
- Insufficient data: Most models need 1+ years of daily data
- Wrong model: Use
aquascope recommendto find the best method for your data - Non-stationary data: Try differencing or use Prophet (handles trends/seasonality)
- Outliers: Run
aquascope quality --file data.json --fixfirst
Visualisation Issues¶
Plots don't display (no window appears)¶
Matplotlib needs an interactive backend. In scripts, use save_path instead:
In Jupyter notebooks, add:
Folium maps not rendering in Jupyter¶
Ensure folium is installed (pip install folium) and the notebook trusts HTML output. Try:
CLI Issues¶
aquascope: command not found¶
Ensure AquaScope is installed in your active environment:
error: unrecognized arguments¶
Check the command's help:
Getting Help¶
- Check the FAQ
- Search existing issues
- Open a new issue with:
- Python version (
python --version) - AquaScope version (
python -c "import aquascope; print(aquascope.__version__)") - Full error traceback
- Minimal reproducing example