Comments (8)
The code does keep all the metadata during the loading process, for the sake of completeness, although it uses UPPER_CASE only. "mintpy.*" metadata is saved to check the processing configurations.
from mintpy.
Hi @EJFielding, the reference_point.py bug is fixed now.
from mintpy.
Hi @EJFielding, 0.0001 deg ~= 10 m on the equator, so I think relaxing it to 3 decimal digits should still be fine.
You could try reference_point.py --write-data
to change the REF_X/Y/LAT/LON
metadata and update the matrix value. MintPy uses UPPER_CASE style for all metadata and is case sensitive.
from mintpy.
Three digits sounds good. Thanks for also mentioning that the metadata is case sensitive and key parameters are UPPER_CASE. It is a bit confusing because info.py
prints out a bunch of parameters that are lower case also, including mintpy.reference.lalo
and ref_lat
. I understand now that the one that matters is the REF_LAT
.
I see that you already changed the comparison to 3 decimal digits or ~100 m, so that seems reasonable.
from mintpy.
By the way, I tried to run the reference_point.py --write-data
command on my time-series step function file and it did not work.
reference_point.py --write-data -l 18.2 -L -67.15 A135_geo_timeseriesStepModel_msk.h5
Using default MintPy Path: /home/fielding/tools/MintPy
--------------------------------------------------
input reference point in lat/lon: (18.2, -67.15)
input reference point in y/x: (330, 179)
--------------------------------------------------
calculating the temporal average of timeseries file: A135_geo_timeseriesStepModel_msk.h5
reading timeseries data from file: A135_geo_timeseriesStepModel_msk.h5 ...
/home/fielding/tools/MintPy/mintpy/objects/stack.py:464: RuntimeWarning: Mean of empty slice
dmean = np.nanmean(data, axis=0)
Traceback (most recent call last):
File "/home/fielding/tools/MintPy/mintpy/reference_point.py", line 447, in <module>
main(sys.argv[1:])
File "/home/fielding/tools/MintPy/mintpy/reference_point.py", line 440, in main
reference_file(inps)
File "/home/fielding/tools/MintPy/mintpy/reference_point.py", line 186, in reference_file
if mask[inps.ref_y, inps.ref_x] == 0.:
IndexError: too many indices for array
Maybe I should open a new issue?
Updating the REF_LAT
and REF_LON
with add_attribute.py
works. I understand that it won't update the values of the array for the new location, but I am only changing the reference point by less than a pixel in this case.
from mintpy.
Hello, I am encountering a similar issue.
I am not able assign a single reference point to my data sets in a scripted fashion, as the rounding error is different for the ascending and descending data sets.
When I use refLat=37.07010 and refLon=89.20000 I get the following error message:
Traceback (most recent call last):
File "/u/sarh0/rzinke/tools/MintPy/mintpy/asc_desc2horz_vert.py", line 278, in <module>
main(sys.argv[1:])
File "/u/sarh0/rzinke/tools/MintPy/mintpy/asc_desc2horz_vert.py", line 258, in main
inps = cmd_line_parse(iargs)
File "/u/sarh0/rzinke/tools/MintPy/mintpy/asc_desc2horz_vert.py", line 101, in cmd_line_parse
raise ValueError('input files do not have the same reference point from REF_LAT/LON values!\n{}'.format(msg))
ValueError: input files do not have the same reference point from REF_LAT/LON values!
file1: 41velocityMaskedRefd.h5, REF_LAT/LON: ['37.071', '89.200'] degrees
file2: 121velocityMaskedRefd.h5, REF_LAT/LON: ['37.070', '89.200'] degrees
I have tried "jiggling" the numbers in various directions, but always I get a similar same error message, with the ascending reference point different from the descending.
I will try removing this check for now, but might need more attention in the future.
from mintpy.
Thanks for bringing it up @rzinke. The current way of checking is not very friendly to datasets with low resolution, we should change it to check if the two reference points are close in terms of pixels, e.g. <=3 pixels. Let's re-open for a reminder.
from mintpy.
@rzinke It seems that there are often some round-off errors that cause the reference points to be slightly different. Updating the REF_LAT
and REF_LON
with add_attribute.py
works on the files to make them exactly the same. This worked for me.
from mintpy.
Related Issues (20)
- Release new version of MintPy to support HyP3 Burst InSAR products HOT 4
- AriaTS_setup HOT 2
- Subset HyP3 datasets and create horz and vert displacement on Jupyter notebook HOT 1
- An error occurred using GACOS data in mintpy HOT 2
- Deprecated numpy.float usage in smallbaselineApp.py breaks with numpy > 1.24.0 HOT 2
- The meaning of numTriNonzeroIntAmbiguity.h5 HOT 1
- output save_gbis.py issue HOT 1
- hyp3 + mintpy: Error in Second Step (Modify Network) HOT 1
- metadata inconsistency for UTM coordinates HOT 4
- `hyp3`: more metadata for `HDF-EOS5` support HOT 6
- The quality of the time series degrades as the distance from the reference point increases. HOT 1
- Support for multiple GNSS HOT 4
- Projection of Liine-of-Sight (LoS) displacement to the downslope component. HOT 3
- `lalo2yx` behaves incorrectly when set of lat/lons cross UTM zone boundary HOT 2
- in the MintPy tutorial of ScopeEarth2023, theSanFranSenDT42.tar HOT 1
- smallbaselineAPP_aria.ipynb in the tutorial of EarthScope2023οΌthe SanFranSenDT42.tar downloaded from zenodo by 'wget' can't be unzip HOT 2
- `view.py numInvIfgram.h5` error for `RidgecrestSenDT71` HOT 1
- Problem with working on step - invert_network HOT 1
- error in prep_gmtsar : not reading *prm files HOT 1
- Request for Large Image Size
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mintpy.