This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import itertools | |
import pandas as pd | |
import numpy as np | |
import plotly.graph_objects as go | |
RESULTS_FILE = "/industry_scratch.csv" | |
data = pd.read_csv(RESULTS_FILE, delimiter=";") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from SPARQLWrapper import JSON, SPARQLWrapper2 | |
DATABUS_ENDPOINT = "https://databus.openenergyplatform.org/sparql" | |
query = """ | |
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> | |
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
""" | |
General description | |
------------------- | |
This example shows how to perform a capacity optimization for | |
an energy system with storage. The following energy system is modeled: | |
.. code-block:: text |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
from urllib.parse import quote | |
MOSS_URL = "http://moss.tools.dbpedia.org/annotation-api-demo/submit" | |
METADATA_URL = "https://openenergy-platform.org/api/v0/schema/model_draft/tables/umas_ninja_pv_country_de_merra_2_nuts_2_corrected/meta/" | |
DATABUS_ARTIFACT = "https://energy.databus.dbpedia.org/henhuy/AP4/modex_capacity_factor" | |
DATABUS_VERSION = "https://energy.databus.dbpedia.org/henhuy/AP4/modex_capacity_factor/v1" | |
DATABUS_DATA = "https://energy.databus.dbpedia.org/henhuy/AP4/modex_capacity_factor/v1/modex_capacity_factor_type=metadata.json" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import abc | |
from typing import Union, List | |
class CalculationError(Exception): | |
"""Raised if something is wrong in calculation""" | |
class Calculator: | |
def __init__(self, scalar_params, scalar_results, sequences_params, sequences_results): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[tool.poetry] | |
name = "solphdep" | |
version = "0.1.0" | |
description = "" | |
authors = ["Henhuy <you@example.com>"] | |
[tool.poetry.dependencies] | |
python = "^3.7" | |
"oemof.solph" = "*" | |
oemoflex = { git = "https://git@github.com/rl-institut/oemoflex", branch = "dev"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import json | |
import ijson | |
import rapidjson | |
import simplejson | |
CONNECTOR_URL = "https://modex.rl-institut.de/scenario/id/" | |
SCENARIO_ID = 42 | |