{"id":21581424,"url":"https://github.com/dlr-eoc/eometadatatool","last_synced_at":"2025-04-30T22:51:29.223Z","repository":{"id":91893680,"uuid":"588617184","full_name":"dlr-eoc/EOmetadataTool","owner":"dlr-eoc","description":"Table controlled Earth Observation metadata extractor and STAC tool","archived":false,"fork":false,"pushed_at":"2024-07-04T14:03:43.000Z","size":10542,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-03-30T20:43:08.683Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dlr-eoc.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-01-13T15:05:01.000Z","updated_at":"2024-12-16T18:35:31.000Z","dependencies_parsed_at":null,"dependency_job_id":"92b777d1-9e1b-47b1-a26e-5e99ff984c16","html_url":"https://github.com/dlr-eoc/EOmetadataTool","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dlr-eoc%2FEOmetadataTool","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dlr-eoc%2FEOmetadataTool/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dlr-eoc%2FEOmetadataTool/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dlr-eoc%2FEOmetadataTool/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dlr-eoc","download_url":"https://codeload.github.com/dlr-eoc/EOmetadataTool/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251795387,"owners_count":21645019,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-24T14:12:28.818Z","updated_at":"2025-04-30T22:51:29.197Z","avatar_url":"https://github.com/dlr-eoc.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# EOmetadataTool\nTable controlled Earth Observation metadata extractor and STAC tool\n\n## Capabilities\n* reads metadata from files in multiple formats like zip, gzip, tar, SAFE, NetCDF, or directory tree;\n* extracts product metadata from one or more files;\n* attribute list and extraction rules specified in a CSV file\n* uses XPath expressions for the metadata extraction;\n* adds XPath functions extensions for common text manipulations: join, regex, map, uppercase, date;\n* creates any desired output format like STAC, EOP XML, JSON [23] using a jinja [22] template;\n* allows using the tool as a python API to embed it in other applications.\n\n## Usage\nExample calls\n* Dump of extracted metadata from a SAFE.zip package\n  ```bash\n  src/metadata_extract/extract.py --scene tests/data/S1A_IW_GRDH_1SDV_20220621T075323_20220621T075348_043758_053961_0000.SAFE.zip \\\n    --mapping src/metadata_extract/mappings/S1_L1L2.csv\n  ```\n* Format the metadata using a jinja2 template - tool automatically determines sentinel-1, 2 or 3 product types following the file naming conventions and selects extraction mapping and output template\n  ```\n  src/metadata_extract/metadata_extract.py --scene tests/data/S2A_MSIL1C_20230216T044851_N0509_R076_T46UEU_20230216T000000.SAFE.zip\n  ```\n\n* Mappings for S5p L2 and L3 are also included, but requires using --mapping and --template parameters\n  ```\n  src/metadata_extract/extract.py --scene tests/data/S5P_OFFL_L2__O3_____20200303T013547_20200303T031717_12367_01_010107_20200306T053811.nc  \\\n    --mapping src/metadata_extract/mappings/S5P_TROPOMI_L2.csv \\\n    --template src/metadata_extract/templates/s5p_l2_stack.j2\n  ```\n\n## Important to know\n* Coordinates are in the format \"Latitude,Longitude\" (this is the default order for Sentinel-1 metadata). Points are separated by space. This order needs be reversed for GeoJSON output (e.g., for geoserver product.json/granules.json)\n\n## Example execution in Python\n```python\nfrom metadata_extract/extract import extract\nextracted_metadata = extract(args.scene, mappings_file, dictFiller)\npprint.pprint(extracted_metadata, width=120)\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdlr-eoc%2Feometadatatool","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdlr-eoc%2Feometadatatool","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdlr-eoc%2Feometadatatool/lists"}