Skip to content

new pyaps0.3.6 can not download dataset #1321

@dmcyfelix

Description

@dmcyfelix

Description of the problem

The program encountered an error at the "step - correct_troposphere" step.

Full script that generated the error

PASTE CODE HERE

Full error message

******************** step - correct_troposphere ********************
Input data seems to be geocoded. Lookup file not needed.
Atmospheric correction using Weather Re-analysis dataset (PyAPS, Jolivet et al., 2011)
Weather Re-analysis dataset: ERA5

tropo_pyaps3.py -f /home/PycharmProjects/hyp3_mintpy/2025_junlian/timeseries.h5 --model ERA5 -g /home/PycharmProjects/hyp3_mintpy/2025_junlian/inputs/geometryGeo.h5 -w ${WEATHER_DIR}
weather model: ERA5 - dry (hydrostatic) and wet delay
weather directory: /home/PycharmProjects/hyp3_mintpy/2025_junlian
output tropospheric delay     time-series file: /home/PycharmProjects/hyp3_mintpy/2025_junlian/inputs/ERA5.h5
output corrected displacement time-series file: /home/PycharmProjects/hyp3_mintpy/2025_junlian/timeseries_ERA5.h5
read dates/time info from file: /home/PycharmProjects/hyp3_mintpy/2025_junlian/timeseries.h5
time of cloest available product: 11:00 UTC
make directory: /home/PycharmProjects/hyp3_mintpy/2025_junlian/ERA5

--------------------------------------------------------------------------------
Download global atmospheric model files...
update mode: ON
output file: /home/PycharmProjects/hyp3_mintpy/2025_junlian/inputs/ERA5.h5
1) output file either do NOT exist or is NOT newer than all GRIB files.
run or skip: run
--------------------------------------------------
downloading weather model data using PyAPS ...
number of grib files to download: 32
--------------------------------------------------
INFO: You are using the latest ECMWF platform for downloading datasets:  https://cds.climate.copernicus.eu/api
2025-02-10 19:32:16,309 INFO [2024-09-26T00:00:00] Watch our [Forum](https://forum.ecmwf.int/) for Announcements, news and other discussed topics.
2025-02-10 19:32:16,309 WARNING [2024-06-16T00:00:00] CDS API syntax is changed and some keys or parameter names may have also changed. To avoid requests failing, please use the "Show API request code" tool on the dataset Download Form to check you are using the correct syntax for your API request.
Downloading 1 of 32: /home/PycharmProjects/hyp3_mintpy/2025_junlian/ERA5/ERA5_N20_N40_E100_E110_20240107_11.grb
{'product_type': ['reanalysis'], 'variable': ['geopotential', 'temperature', 'specific_humidity'], 'year': ['2024'], 'month': ['01'], 'day': ['07'], 'time': ['11:00'], 'pressure_level': ['1', '2', '3', '5', '7', '10', '20', '30', '50', '70', '100', '125', '150', '175', '200', '225', '250', '300', '350', '400', '450', '500', '550', '600', '650', '700', '750', '775', '800', '825', '850', '875', '900', '925', '950', '975', '1000'], 'data_format': 'grib', 'area': [40, 100, 20, 110]}
WARNING: the 1 attempt to download failed, retry it.

INFO: You are using the latest ECMWF platform for downloading datasets:  https://cds.climate.copernicus.eu/api
2025-02-10 19:32:17,285 INFO [2024-09-26T00:00:00] Watch our [Forum](https://forum.ecmwf.int/) for Announcements, news and other discussed topics.
2025-02-10 19:32:17,285 WARNING [2024-06-16T00:00:00] CDS API syntax is changed and some keys or parameter names may have also changed. To avoid requests failing, please use the "Show API request code" tool on the dataset Download Form to check you are using the correct syntax for your API request.
Downloading 1 of 32: /home/PycharmProjects/hyp3_mintpy/2025_junlian/ERA5/ERA5_N20_N40_E100_E110_20240107_11.grb
{'product_type': ['reanalysis'], 'variable': ['geopotential', 'temperature', 'specific_humidity'], 'year': ['2024'], 'month': ['01'], 'day': ['07'], 'time': ['11:00'], 'pressure_level': ['1', '2', '3', '5', '7', '10', '20', '30', '50', '70', '100', '125', '150', '175', '200', '225', '250', '300', '350', '400', '450', '500', '550', '600', '650', '700', '750', '775', '800', '825', '850', '875', '900', '925', '950', '975', '1000'], 'data_format': 'grib', 'area': [40, 100, 20, 110]}
WARNING: the 2 attempt to download failed, retry it.

INFO: You are using the latest ECMWF platform for downloading datasets:  https://cds.climate.copernicus.eu/api
2025-02-10 19:32:18,258 INFO [2024-09-26T00:00:00] Watch our [Forum](https://forum.ecmwf.int/) for Announcements, news and other discussed topics.
2025-02-10 19:32:18,258 WARNING [2024-06-16T00:00:00] CDS API syntax is changed and some keys or parameter names may have also changed. To avoid requests failing, please use the "Show API request code" tool on the dataset Download Form to check you are using the correct syntax for your API request.
Downloading 1 of 32: /home/PycharmProjects/hyp3_mintpy/2025_junlian/ERA5/ERA5_N20_N40_E100_E110_20240107_11.grb
{'product_type': ['reanalysis'], 'variable': ['geopotential', 'temperature', 'specific_humidity'], 'year': ['2024'], 'month': ['01'], 'day': ['07'], 'time': ['11:00'], 'pressure_level': ['1', '2', '3', '5', '7', '10', '20', '30', '50', '70', '100', '125', '150', '175', '200', '225', '250', '300', '350', '400', '450', '500', '550', '600', '650', '700', '750', '775', '800', '825', '850', '875', '900', '925', '950', '975', '1000'], 'data_format': 'grib', 'area': [40, 100, 20, 110]}


**************************************************
WARNING: downloading failed for 3 times, stop trying and continue.
**************************************************



--------------------------------------------------------------------------------
Calculate tropospheric delay and write to HDF5 file...
update mode: ON
output file: /home/PycharmProjects/hyp3_mintpy/2025_junlian/inputs/ERA5.h5
1) output file either do NOT exist or is NOT newer than all GRIB files.
run or skip: run
open geometry file: geometryGeo.h5
reading incidenceAngle  data from file: /home/PycharmProjects/hyp3_mintpy/2025_junlian/inputs/geometryGeo.h5 ...
reading height          data from file: /home/PycharmProjects/hyp3_mintpy/2025_junlian/inputs/geometryGeo.h5 ...
UTM coordinates detected, convert UTM into lat/lon
--------------------------------------------------
create HDF5 file: /home/PycharmProjects/hyp3_mintpy/2025_junlian/inputs/ERA5.h5 with w mode
create dataset  : date       of |S1                       in size of (0,)                 with compression = None
create dataset  : timeseries of <class 'numpy.float32'>   in size of (0, 2837, 3579)      with compression = None
close  HDF5 file: /home/PycharmProjects/hyp3_mintpy/2025_junlian/inputs/ERA5.h5
--------------------------------------------------
calculating absolute delay for each date using PyAPS (Jolivet et al., 2011; 2014) ...
number of grib files used: 0
Traceback (most recent call last):
  File "/root/miniconda3/envs/hyp3-mintpy/bin/smallbaselineApp.py", line 10, in <module>
    sys.exit(main())
  File "/root/miniconda3/envs/hyp3-mintpy/lib/python3.9/site-packages/mintpy/cli/smallbaselineApp.py", line 209, in main
    run_smallbaselineApp(inps)
  File "/root/miniconda3/envs/hyp3-mintpy/lib/python3.9/site-packages/mintpy/smallbaselineApp.py", line 1155, in run_smallbaselineApp
    app.run(steps=inps.runSteps)
  File "/root/miniconda3/envs/hyp3-mintpy/lib/python3.9/site-packages/mintpy/smallbaselineApp.py", line 935, in run
    self.run_tropospheric_delay_correction(sname)
  File "/root/miniconda3/envs/hyp3-mintpy/lib/python3.9/site-packages/mintpy/smallbaselineApp.py", line 682, in run_tropospheric_delay_correction
    mintpy.cli.tropo_pyaps3.main(iargs)
  File "/root/miniconda3/envs/hyp3-mintpy/lib/python3.9/site-packages/mintpy/cli/tropo_pyaps3.py", line 166, in main
    run_tropo_pyaps3(inps)
  File "/root/miniconda3/envs/hyp3-mintpy/lib/python3.9/site-packages/mintpy/tropo_pyaps3.py", line 741, in run_tropo_pyaps3
    calc_delay_timeseries(inps)
  File "/root/miniconda3/envs/hyp3-mintpy/lib/python3.9/site-packages/mintpy/tropo_pyaps3.py", line 671, in calc_delay_timeseries
    prog_bar = ptime.progressBar(maxValue=num_date, print_msg=~inps.verbose)
  File "/root/miniconda3/envs/hyp3-mintpy/lib/python3.9/site-packages/mintpy/objects/progress.py", line 84, in __init__
    self.reset()
  File "/root/miniconda3/envs/hyp3-mintpy/lib/python3.9/site-packages/mintpy/objects/progress.py", line 90, in reset
    self.update_amount(0)  # Build progress bar string
  File "/root/miniconda3/envs/hyp3-mintpy/lib/python3.9/site-packages/mintpy/objects/progress.py", line 109, in update_amount
    percentDone = (diffFromMin / float(self.span)) * 100.0
ZeroDivisionError: float division by zero

System information

  • Operating system:
  • Python environment:
  • MintPy version:
  • InSAR processor/product:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions