Skip to content

Commit

Permalink
Merge pull request #4 from IFRCGo/EMDAT
Browse files Browse the repository at this point in the history
Add EM-DAT source specifications
  • Loading branch information
emmanuelmathot authored Jan 16, 2025
2 parents 1e56c16 + 0d27567 commit c8b8930
Show file tree
Hide file tree
Showing 18 changed files with 745 additions and 133 deletions.
1 change: 0 additions & 1 deletion .github/remark.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,3 @@ plugins:
- space
# Tables
- remark-lint-table-pipes
- remark-lint-no-literal-urls
13 changes: 8 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,12 @@ It is the unique identifier assigned by the Monty system to an episode of the ev

##### monty:country_codes

It is a list of country codes of the countries concerned by the item.
It is a list of country codes of the countries concerned by the item.
It must at least contain the countries intersected by the item's geometry.

##### monty:hazard_codes

It is a list of hazard codes of the hazards concerned by the item.
It is a list of hazard codes of the hazards concerned by the item.
The hazard code SHOULD follow the [UNDRR-ISC 2020 Hazard Information Profiles](https://www.preventionweb.net/drr-glossary/hips) identifier.
With that identifier, it is possible to derive a set of additional properties associated with the hazard:

Expand Down Expand Up @@ -183,7 +183,7 @@ The global crisis data bank records multiple instances of events that are relate
- One **unique reference** event that is used to "[pair](model/event_paring.md)" all the instances of the event
- Multiple instances of the event that are recorded for different sources. Each source event **MUST** have the following:
- A link to the reference event with the [relationship](#relation-types) type `reference-event`
- A link to the resource from which the event was sourced with
- A link to the resource from which the event was sourced with
the [relationship](https://github.com/radiantearth/stac-spec/blob/master/best-practices.md#using-relation-types) type `via`.

## Data
Expand Down Expand Up @@ -251,23 +251,26 @@ for running tests are copied here for convenience.

### Running tests

The same checks that run as checks on PR's are part of the repository and can be run locally to verify that changes are valid.
The same checks that run as checks on PR's are part of the repository and can be run locally to verify that changes are valid.
To run tests locally, you'll need `npm`, which is a standard part of any [node.js installation](https://nodejs.org/en/download/).

First you'll need to install everything with npm once. Just navigate to the root of this repository and on
First you'll need to install everything with npm once. Just navigate to the root of this repository and on
your command line run:

```bash
npm install
```

Then to check markdown formatting and test the examples against the JSON schema, you can run:

```bash
npm test
```

This will spit out the same texts that you see online, and you can then go and fix your markdown or examples.

If the tests reveal formatting problems with the examples, you can fix them with:

```bash
npm run format-examples
```
76 changes: 76 additions & 0 deletions examples/emdat-events/2024-0796-ESP.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
{
"type": "Feature",
"stac_version": "1.0.0",
"stac_extensions": [
"https://ifrcgo.github.io/monty/v0.1.0/schema.json"
],
"id": "emdat-event-2024-0796-ESP",
"geometry": {
"type": "Polygon",
"coordinates": [
[
[
-9,
36
],
[
-9,
44
],
[
3,
44
],
[
3,
36
],
[
-9,
36
]
]
]
},
"bbox": [
-9,
36,
3,
44
],
"properties": {
"title": "Flood (Flood (General)) in Spain of October 2024",
"description": "Flood (Flood (General)) in Alaquàs, Albal, Aldaya, Alfafar, Algemesí, Benerússer, Catarroja, Llocnou de la Corona, Massanassa, Paiporta, Picanya, Sedaví, Utiel and La Torre municipalties (Valencia);, Letur, lbacete provinces; Castilla-La Mancha communities, Andalusia, Murcia, and the Balearic Islands, Catalonia, Spain of October 2024",
"start_datetime": "2024-10-27T00:00:00Z",
"end_datetime": "2024-11-04T00:00:00Z",
"monty:episode_number": 1,
"monty:hazard_codes": [
"FL"
],
"monty:country_codes": [
"ESP"
],
"monty:corr_id": "20241027-ESP-FL-1-GCDB",
"roles": [
"source",
"event"
],
"datetime": "2024-10-27T00:00:00Z"
},
"links": [
{
"rel": "collection",
"href": "/home/emathot/Workspace/IFRCGo/pystac-monty/emdat-events.json",
"type": "application/json",
"title": "EM-DAT Source Events"
},
{
"rel": "via",
"href": "https://public.emdat.be/data/2024-0796-ESP",
"type": "text/html",
"title": "EM-DAT Event Data"
}
],
"assets": {},
"collection": "emdat-events"
}
70 changes: 70 additions & 0 deletions examples/emdat-events/emdat-events.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
{
"stac_version": "1.0.0",
"stac_extensions": [
"https://ifrcgo.github.io/monty/v0.1.0/schema.json"
],
"type": "Collection",
"id": "emdat-events",
"title": "EM-DAT Source Events",
"description": "Global Disaster Events from the Emergency Events Database (EM-DAT).",
"license": "MIT",
"roles": [
"event",
"source"
],
"providers": [
{
"name": "EM-DAT",
"roles": [
"producer"
],
"url": "https://www.emdat.be/",
"email": "contact@cred.be"
}
],
"extent": {
"spatial": {
"bbox": [
[
-180,
-90,
180,
90
]
]
},
"temporal": {
"interval": [
[
"1988-01-01T00:00:00Z",
null
]
]
}
},
"summaries": {
"datetime": {
"minimum": "2015-06-23T00:00:00Z",
"maximum": "2019-07-10T13:44:56Z"
},
"roles": [
"event",
"source"
],
"monty:country_codes": [
"CHN",
"SPN"
],
"monty:hazard_codes": [
"MH0004",
"MH0005",
"MH0006"
]
},
"links": [
{
"href": "emdat-events.json",
"rel": "self"
}
]
}
70 changes: 70 additions & 0 deletions examples/emdat-hazards/emdat-hazards.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
{
"stac_version": "1.0.0",
"stac_extensions": [
"https://ifrcgo.github.io/monty/v0.1.0/schema.json"
],
"type": "Collection",
"id": "emdat-hazards",
"title": "EM-DAT Source Hazards",
"description": "Global Disaster Events from the Emergency Events Database (EM-DAT).",
"license": "MIT",
"roles": [
"hazard",
"source"
],
"providers": [
{
"name": "EM-DAT",
"roles": [
"producer"
],
"url": "https://www.emdat.be/",
"email": "contact@cred.be"
}
],
"extent": {
"spatial": {
"bbox": [
[
-180,
-90,
180,
90
]
]
},
"temporal": {
"interval": [
[
"1988-01-01T00:00:00Z",
null
]
]
}
},
"summaries": {
"datetime": {
"minimum": "2015-06-23T00:00:00Z",
"maximum": "2019-07-10T13:44:56Z"
},
"roles": [
"event",
"source"
],
"monty:country_codes": [
"CHN",
"SPN"
],
"monty:hazard_codes": [
"MH0004",
"MH0005",
"MH0006"
]
},
"links": [
{
"href": "emdat-hazards.json",
"rel": "self"
}
]
}
70 changes: 70 additions & 0 deletions examples/emdat-impacts/emdat-impacts.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
{
"stac_version": "1.0.0",
"stac_extensions": [
"https://ifrcgo.github.io/monty/v0.1.0/schema.json"
],
"type": "Collection",
"id": "emdat-impacts",
"title": "EM-DAT Source Impacts",
"description": "Global Disaster Events from the Emergency Events Database (EM-DAT).",
"license": "MIT",
"roles": [
"impact",
"source"
],
"providers": [
{
"name": "EM-DAT",
"roles": [
"producer"
],
"url": "https://www.emdat.be/",
"email": "contact@cred.be"
}
],
"extent": {
"spatial": {
"bbox": [
[
-180,
-90,
180,
90
]
]
},
"temporal": {
"interval": [
[
"1988-01-01T00:00:00Z",
null
]
]
}
},
"summaries": {
"datetime": {
"minimum": "2015-06-23T00:00:00Z",
"maximum": "2019-07-10T13:44:56Z"
},
"roles": [
"event",
"source"
],
"monty:country_codes": [
"CHN",
"SPN"
],
"monty:hazard_codes": [
"MH0004",
"MH0005",
"MH0006"
]
},
"links": [
{
"href": "emdat-impacts.json",
"rel": "self"
}
]
}
Loading

0 comments on commit c8b8930

Please sign in to comment.