Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: OSeMOSYS/simplicity
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v1.0
Choose a base ref
...
head repository: OSeMOSYS/simplicity
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
  • 4 commits
  • 4 files changed
  • 3 contributors

Commits on Mar 15, 2023

  1. Add Zenodo metadata

    willu47 committed Mar 15, 2023
    Copy the full SHA
    533eea9 View commit details
  2. Update readme with new links

    willu47 committed Mar 15, 2023
    Copy the full SHA
    3ff463b View commit details

Commits on Apr 25, 2023

  1. Copy the full SHA
    15f8d1c View commit details
  2. Merge pull request #10 from trevorb1/readme-updates

    updates zenodo wget and otoole version
    trevorb1 authored Apr 25, 2023
    Copy the full SHA
    2e6a80c View commit details
Showing with 34 additions and 63 deletions.
  1. +18 −0 .zenodo.json
  2. +15 −8 README.md
  3. +1 −1 data/DiscountRate.csv
  4. +0 −54 data/default_values.csv
18 changes: 18 additions & 0 deletions .zenodo.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"license": "CC-BY-4.0",
"upload_type": "dataset",
"title": "OSeMOSYS Example Model: Simplicity",
"creators": [
{
"name": "Will Usher",
"affiliation": "KTH Royal Institute of Technology",
"orcid": "0000-0001-9367-1791"
},
{
"name": "Trevor Barnes",
"affiliation": "Simon Fraser University",
"orcid": "0000-0003-2458-2968"
}
],
"access_right": "open"
}
23 changes: 15 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -4,23 +4,30 @@

This is an example OSeMOSYS model used to demonstrate the functionality of the Python
package [otoole](https://github.com/OSeMOSYS/otoole). You can use **otoole** to generate
a GNU MathProg data file from the dataset with the following commands. Full
**otoole** documentation (including installation and examples) can be found on
its [ReadTheDocs site](https://otoole.readthedocs.io/en/latest/).
a GNU MathProg data file from the dataset with the following commands. Full
**otoole** documentation (including installation and examples) can be found on
its [ReadTheDocs site](https://otoole.readthedocs.io/en/latest/).

**NOTE**: To be able to solve the model in this example, you will need to install
**NOTE**: To be able to solve the model in this example, you will need to install
the free and open-source solver [GLPK](https://www.gnu.org/software/glpk/)

```bash
# Install the OSeMOSYS toolkit
pip install otoole>=1.0.0
pip install "otoole>=1.0.0"

# Download the dataset. On Linux or OSX use wget, otherwise download and unzip
wget https://zenodo.org/record/3707794/files/OSeMOSYS/simplicity-v0.2.1.zip
unzip simplicity-v0.2.1.zip -d simplicity
wget https://zenodo.org/record/7736836/files/OSeMOSYS/simplicity-v1.1.zip?download=1
unzip simplicity-v1.1.zip?download=1 -d simplicity

# Move the data to a new directory called simplicity/
mv simplicity/OSeMOSYS-simplicity-74b9610/* simplicity
rm -R simplicity/OSeMOSYS-simplicity-74b9610/

# Change working directory to the new simplicity folder
cd simplicity

# Create the GNUMathProg data file with otoole
otoole convert csv datafile simplicity/data ./simplicity.txt simplicity/config.yaml
otoole convert csv datafile data/ ./simplicity.txt config.yaml

# Solve the model
glpsol -m OSeMOSYS.txt -d simplicity.txt
2 changes: 1 addition & 1 deletion data/DiscountRate.csv
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
REGION,TECHNOLOGY,VALUE
REGION,VALUE

54 changes: 0 additions & 54 deletions data/default_values.csv

This file was deleted.