EnergySystemsModellingLab / EnergySystemsModellingLab/MUSE2
Allow for including trade input file
- Lingua principale
- Rust
- Stelle
- 8
- Fork
- 5
- Merge medio
- 1g 2m
- PR unite (30g)
- 37
Descrizione
We probably want this to be broadly like @tsmbland's suggestion here: https://github.com/EnergySystemsModellingLab/MUSE2/issues/523#issuecomment-4499524654
I don't think we should use the word "processes" in the file name. We can call these relationships "trade processes" among ourselves, but I think it might confuse users who aren't aware of the internal code structure. How about we just call this file `trade.csv`?
Here's what I personally think the file should look like, for the first implentation:
```csv
commodity_id,start_year,end_year,source_regions,destination_regions,import_levy,export_levy
COAL,,,UK,FRA,1,0
```
There are a few extra features compared to Tom's initial suggestion:
- You can limit the trade relationship to a specified year range (or omit, meaning all milestone years)
- You can specify multiple source and destination regions (if you put either as `all`, we obvs wouldn't apply these properties to regions "trading" with themselves)
- You can have different levies for import/export
I think the way we should implement this is by building up maps of trade relationships as we go through the CSV file, line by line and storing import/export levies separately (as we do for commodity levies). If two entries overlap in commodity, milestone year, source region, destination region and whether its an import or export levy, then we give an error.
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Inizia esaminando la proposta collegata e lo schema trade.csv proposto in questa issue. Traccia il modo in cui i dazi sulle merci vengono letti e memorizzati, quindi determina dove dovrebbero essere costruite le relazioni commerciali e i dazi separati su importazioni ed esportazioni; il lavoro è completato quando sono supportate le regole indicate per anno, regione, dazio ed errori di sovrapposizione.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- rust
- Ambito
- data
- Tipo di issue
- Funzionalità
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Stato di attività
- Tranquilla
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 35/100