Repository navigation
Conversation
The default mapping carried a building's demand as one constant electricity load derived from demand_energy and mapped no other carrier. EnerPlanET now computes each building's demand per step with a building thermal model and lets users assign heat and cooling technologies, none of which reached MEME. properties.demand_series maps electricity, heat, cooling and natural_gas to series in kW. Each becomes a model.timeseries entry in MW (rounded to nine decimals, six in kW on the way back) and a demand technology whose demand_profile names it: demand_$k for electricity, which replaces the constant load, and demand_heat_$k, demand_cooling_$k and demand_natural_gas_$k for the others. Keys other than these four are not carried. Heat pumps and the electric boiler convert electricity to heat, the gas boiler converts natural gas to heat and the air conditioner electricity to cooling, each with cont_energy_eff as efficiency and the shared capacity and cost rules. gas_supply becomes a gas import, trade gas_$k, priced like the electricity tariffs; no gas network is modelled. The heat, cooling and natural_gas carriers are added only by the rules that use them. A payload without series or these technologies produces the same job as before: the examples and golden files are unchanged. The reverse restores the series as kW arrays and the technologies under techs; the constant electricity rule only reverses a numeric demand_profile, so a series reference is left to the series rule. The mapping's version is now 1.2.0. Fixes #2
This was referenced Oct 16, 2026
Closed
jravani
added a commit
to enerplanet/enerplanet
that referenced
this pull request
Oct 16, 2026
EnerPlanET attaches each building's BuEM series to the MEME payload (properties.demand_series), but T1K v0.1.0 ignores that field, so a run still sent one constant electricity load per building. The mapping that carries the series, heat, cooling and gas is enerplanet/T1K#3, not yet released. The backend now requires T1K at that commit (f21e43e, pseudo-version v0.1.1-0.20261016020843-f21e43e03059). It moves to the release tag once the PR is released. The comment on TranslatePayload no longer says the mapping is electricity only.
A building's PV reached MEME as one pv_supply technology with physics
parameters and no profile. MEME's Calliope and PyPSA targets need a
precomputed profile for a physics technology, and a building can carry
PV on several roof surfaces with different orientations.
techs.pv_arrays lists the arrays of a building, one per surface. Array
$j becomes the series pv_${k}_$j (source inline, unit fraction, the
profile in kW AC per kW DC unchanged) and the supply technology
pv_supply_${k}_$j, whose performance.precomputed names that series. The
technology takes tilt, azimuth and losses as physics parameters and the
shared capacity and cost rules, so cont_energy_cap_max bounds the
array's size. surface_id is not carried. techs.pv_supply is mapped as
before.
A payload without pv_arrays produces the same job as before: the
examples and golden files are unchanged. The reverse restores the
arrays with their profiles. The mapping's version is now 1.3.0.
feat(config): map PV arrays with their own production profiles
Member
Author
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #2.
Carries a building's demand per step (electricity, heat, cooling, natural gas) and its heat and cooling technologies from the EnerPlanET payload to MEME. MEME needs no change: it already accepts named series, any carrier,
conversiontechs andtradeimports per carrier.Mapping (version 1.2.0)
properties.demand_series.<carrier>(kW per step) becomesmodel.timeseries{demand_$k},{demand_heat_$k},{demand_cooling_$k}or{demand_natural_gas_$k}(MW), plus a demand technology whosedemand_profilenames it. An electricity series replaces the constant load ofdemand_energy;demand_$kkeeps its key.air_source_heat_pump,ground_source_heat_pumpandelectric_boilersconvert electricity to heat.gas_boilerconverts natural gas to heat, andair_conditionerconverts electricity to cooling. All usecont_energy_effasefficiencywith the sharedtech_capacityandtech_costsrules.gas_supplybecomestrade{gas_$k}, a natural gas import priced likehouseholds_supply. No gas network is modelled.heat,coolingandnatural_gascarriers are added only when a rule uses them.Effect on the reverse
techs.<name>.demand_profile gte 0, so a series reference (a string) is left to the series rule instead of failing inlinear.Checks
make test-race: passes. New cases inpkg/t1k/mapping_test.go:TestMappingDemandSeries: all four carriers; a series withdemand_energy0; an unknown carrier key; no carriers added without series.TestMappingHeatTechnologies: each technology and the gas import.TestMappingRoundTripAllKinds: now includes a building with series and every new technology.make fuzz FUZZTIME=10s: passes.make golden-updateandmake exampleleave the golden files and examples unchanged.golangci-lintwas not available locally; CI runs it.enerplanet/mememain, Calliope 0.7.0.dev7): the example payload extended to a full year (2018, 60 min), with one building given 8760-step BuEM series for electricity, heat and cooling, a gas cooking series, a heat pump, a gas boiler, an air conditioner and a gas supply. PV was removed from the payload because MEME requires a precomputed PV profile for Calliope./validate?target=calliope:valid: true, with only the two warnings the existing unmet-demand and solver constants already produce./simulate?target=calliope: succeeded. Calliope built the gas boiler (13.2 kW of heat from 14.6 kW of gas) and an 8.3 kW air conditioner, with no unmet heat, cooling or gas. The only unmet electricity is atn4, the example's building without a connection.Docs: the mapping page gains a Demand series section and rows for the new technologies; the CHANGELOG has the entry under Unreleased.