m9brady / eodms-api-client Goto Github PK
View Code? Open in Web Editor NEWEODMS API Client for Python
Home Page: https://m9brady.github.io/eodms-api-client/
License: MIT License
EODMS API Client for Python
Home Page: https://m9brady.github.io/eodms-api-client/
License: MIT License
I am running eodms from a conda shell in Win 10 with python 3.10 and after executing eodms -c RCM --order-id myid
the download initiates as intended and all the ordered files are created, but their size never exceeds 1kb. Also there is no visible progress in the terminal. It is stuck like this:
2022-10-19 11:21:05 | eodmsapi.cli | INFO | Fast-downloading for 1 order 2022-10-19 11:21:05 | eodmsapi.main | INFO | Checking status of 1 order 2022-10-19 11:21:17 | eodmsapi.main | INFO | 50/50 items ready for download 2022-10-19 11:21:17 | eodmsapi.main | INFO | 0/50 items exist locally 2022-10-19 11:21:17 | eodmsapi.main | INFO | Downloading 50 remote items RCM1_OK1971291_PK2020755_1_SC50MC_20220316_170808_HH_HV_GRD.zip: 0%| | 121/619M [00:00<?, ?B/s] RCM3_OK1971291_PK2021980_1_SC50MD_20220317_051443_HH_HV_GRD.zip: 0%| | 121/156M [00:00<22:50, 119kB/s] RCM2_OK1971292_PK2017968_1_SC50MA_20220315_053123_HH_HV_GRD.zip: 0%| | 121/712M [00:00<?, ?B/s] RCM1_OK1971292_PK2020756_1_SC50MC_20220316_170808_HH_HV_GRD.zip: 0%| | 121/677M [00:00<?, ?B/s] RCM3_OK1971292_PK2028828_1_SC50MA_20220319_053137_HH_HV_GRD.zip: 0%| | 121/785M [00:00<?, ?B/s] RCM3_OK1971292_PK2021981_2_SC50MD_20220317_051443_HH_HV_GRD.zip: 0%| | 121/280M [00:00<?, ?B/s] RCM2_OK1799892_PK2018094_1_QP9_20220315_053153_HH_VV_HV_VH_SLC.zip: 0%| | 121/453M [00:00<?, ?B/s] RCM2_OK1971291_PK2035215_1_SC50MD_20220325_051432_HH_HV_GRD.zip: 0%| | 121/156M [00:00<?, ?B/s] RCM2_OK1955819_PK2052959_1_QP10_20220410_164420_HH_VV_HV_VH_SLC.zip: 0%| | 121/511M [00:00<?, ?B/s] RCM2_OK1971292_PK2027085_1_SC50MA_20220318_165213_HH_HV_GRD.zip: 0%| | 121/1.91G [00:00<?, ?B/s] RCM3_OK1971292_PK2021981_1_SC50MD_20220317_051443_HH_HV_GRD.zip: 0%| | 121/1.96G [00:00<?, ?B/s] RCM2_OK1971291_PK2027082_1_SC50MA_20220318_165213_HH_HV_GRD.zip: 0%| | 121/449M [00:00<?, ?B/s] RCM2_OK1971292_PK2035216_2_SC50MD_20220325_051432_HH_HV_GRD.zip: 0%| | 121/280M [00:00<?, ?B/s] RCM2_OK1971291_PK2029731_1_SC50MC_20220320_170819_HH_HV_GRD.zip: 0%| | 121/619M [00:00<?, ?B/s] RCM3_OK1799892_PK2031123_1_QP11_20220321_164431_HH_VV_HV_VH_SLC.zip: 0%| | 121/557M [00:00<?, ?B/s] RCM1_OK1799892_PK2031900_1_QP22_20220322_052341_HH_VV_HV_VH_SLC.zip: 0%|
There is no error message or an indication that the connection might be affected. Is this a server side issue or do I have to fix something locally?
Thanks and best regards
Tried to query eodms api for R2 dataset and limit query to SGF (-pt), SCWA (-bm) with no success. Could be an issue with EODMS itself since I sometimes have similar issues when querying EODMS for their online portal...
eodms -c Radarsat2 -s 20180205 -e 20181231 -pt SGF -g CG_EODMS_Query.geojson -dr
Got a KeyError when I tried to query NAPL.
eodms -c NAPL -g query_aoi.geojson --verbose
2022-09-14 22:45:06 | eodmsapi.cli | DEBUG | Connecting to EODMS
Enter EODMS username: cmancuso
Enter EODMS password:
2022-09-14 22:45:11 | eodmsapi.cli | DEBUG | Connected to EODMS
2022-09-14 22:45:11 | eodmsapi.cli | INFO | Querying EODMS API
2022-09-14 22:45:13 | eodmsapi.main | WARNING | No results found
Traceback (most recent call last):
File "/home/cmancuso/miniconda3/envs/eodms-env/lib/python3.10/site-packages/pandas/core/indexes/base.py", line 3629, in get_loc
return self._engine.get_loc(casted_key)
File "pandas/_libs/index.pyx", line 136, in pandas._libs.index.IndexEngine.get_loc
File "pandas/_libs/index.pyx", line 163, in pandas._libs.index.IndexEngine.get_loc
File "pandas/_libs/hashtable_class_helper.pxi", line 5198, in pandas._libs.hashtable.PyObjectHashTable.get_item
File "pandas/_libs/hashtable_class_helper.pxi", line 5206, in pandas._libs.hashtable.PyObjectHashTable.get_item
KeyError: 'Incidence Angle (Low)'
Submitted:
eodms -c Radarsat2 --record-ids ListOfIdsToDownload.txt --dump-results
Received this:
2021-02-12 10:47:52 | eodmsapi.cli | INFO | Fast-ordering for 54 record(s)
2021-02-12 10:47:52 | eodmsapi.main | INFO | Submitting order for 1 item
2021-02-12 10:47:52 | eodmsapi.cli | INFO | EODMS Order Ids for tracking progress: ['229386']
Traceback (most recent call last):
File "c:\users\username\appdata\local\continuum\anaconda3\envs\tf2\lib\runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "c:\users\username\appdata\local\continuum\anaconda3\envs\tf2\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Users\username\AppData\Local\Continuum\anaconda3\envs\tf2\Scripts\eodms.exe\__main__.py", line 7, in <module>
File "c:\users\username\appdata\local\continuum\anaconda3\envs\tf2\lib\site-packages\click\core.py", line 764, in __call__
return self.main(*args, **kwargs)
File "c:\users\username\appdata\local\continuum\anaconda3\envs\tf2\lib\site-packages\click\core.py", line 717, in main
rv = self.invoke(ctx)
File "c:\users\username\appdata\local\continuum\anaconda3\envs\tf2\lib\site-packages\click\core.py", line 956, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "c:\users\username\appdata\local\continuum\anaconda3\envs\tf2\lib\site-packages\click\core.py", line 555, in invoke
return callback(*args, **kwargs)
File "c:\users\username\appdata\local\continuum\anaconda3\envs\tf2\lib\site-packages\eodms_api_client\cli.py", line 257, in cli
's' if n_results != 1 else '',
UnboundLocalError: local variable 'n_results' referenced before assignment
Still got an email from EODMS saying they are preparing my order for the file ListOfIdsToDownload.txt
ListOfIdsToDownload.txt
Tried to query multiple beam modes in one query but only got one beam mode or all of them.
Tried:
x = EodmsAPI('RCM')
x.query(start='2019-07-01', end='2020-10-20', geometry='Data/CG_EODMS_Query.geojson', polarization='HH HV',
beam_mode='Low Noise Med Resolution 50m Low Resolution 100m')
Got all beam modes.
And
x = EodmsAPI('RCM')
x.query(start='2019-07-01', end='2020-10-20', geometry='Data/CG_EODMS_Query.geojson', polarization='HH HV',
beam_mode=['Low Noise, Med Resolution 50m, Low Resolution 100m'])
Only got the first beam mode in the list. Note: if I change the order of the beam modes in the list, I get the first beam mode.
For now, I use all the beam modes and sort the results post query. Thanks!
Describe the bug
EODMS API was updated alongside a server version upgrade and has several changes in behaviour
To Reproduce
Try to order/download using this package
Additional context
Searching:
Ordering:
SUBMITTED
stage
Downloading:
?orderId=<num>
parameter used to provide only the scenes that belong to an order but now it always responds with the last-100-ordered scenesDescribe the bug
The request IDs on the website seem to be 1 higher than the one returned by the client.query() method.
To Reproduce
Query and order products from RCM. Navigate to the portal -> My Orders. Compare the Order ID column from the portal to the order ID in the query results.
Expected behavior
Order ids should match.
Additional context
Package version: 1.0.1
When querying with the polarization filter I get 0 results but if I remove the filter, I get 932 results which most of them have the desired polarization HH+HV.
eodms -c RCM -s 2019-08-01 -e 2020-07-31 -g "G:\Shapefile\CG_EODMS_Query.geojson" -rp "HH+HV" -dr
The geojson polygon file.
https://geojson.io/#map=7/68.094/-111.643
I noticed that in the attribute table the polarization appears as "HH HV". Issue with the "+" in the query input?
When ordering with the --record-id option (only) the order was placed without having set the --submit-order option.
e.g. eodms -c RCM --record-id 6887647
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.