Comments (7)
I don't see a reason why there needs to be a translation to "Variables" at the end, in particular because the groupby vintage_year
is probably not always true.
An easier way would be to identify any of the types 'primitives', 'derivatives' and 'aggregates' by an IAMC-compliant variable.
from message_ix.
Another observation: the linearity is not always true. As an example, take energy intensity of GDP. To compute that at the global level, you need to first aggregate, then derive.
from message_ix.
I don't see a reason why there needs to be a translation to "Variables" at the end, in particular because the
groupby vintage_year
is probably not always true.An easier way would be to identify any of the types 'primitives', 'derivatives' and 'aggregates' by an IAMC-compliant variable.
My initial thought on the "Variables" section is that there we "lose" information from the model. For example, in order to accurately calculate some aggregate, we may need to weight by vintage year. In the IAMC data template, there is no explicit mention of this (i.e., it is message_ix model specific). Thus this would be a interface/processing step invoked after all operations are performed that need message_ix-specific information.
In any case, I completely agree that we should plan to support "optimization" of the process to calculate only those data that users are interested in. Using this proposal, one way would be to:
- take a list of IAMC variables of interest as input
- identify all necessary root nodes (Cost|Fossil Fuel in this case)
- work up the tree to identify necessary aggregates/derivatives/primitives
- initiate the process listing only necessary data
from message_ix.
Another observation: the linearity is not always true. As an example, take energy intensity of GDP. To compute that at the global level, you need to first aggregate, then derive.
Point taken that this proposal may not fit all use cases (that I haven't thought of!), but (as discussed in person) this example could be computed as follows:
- regional EI: energy / GDP
- global EI: GDP weighted sum of regional EI
from message_ix.
In any case, I completely agree that we should plan to support "optimization" of the process to calculate only those data that users are interested in. Using this proposal, one way would be to:
- take a list of IAMC variables of interest as input
- identify all necessary root nodes (Cost|Fossil Fuel in this case)
- work up the tree to identify necessary aggregates/derivatives/primitives
- initiate the process listing only necessary data
The machine learning world has spawned a lot of packages for managing "workflows". Here's an example from Google's TensorFlow (look at the flowchart). The idea is that each item to be calculated depends on its inputs, in a directed acyclic graph (DAG). Identifying a subset of the nodes and edges is called "pruning".
Usually this is done so that, in big data applications, the different operations can be farmed out/parallelized across multiple nodes/languages. MESSAGE doesn't need those features, so e.g. Luigi is overkill. But we could locate and take advantage of existing packages that implements (including pruning) DAGs…e.g. dask implements graphs; I just stumbled across Pinball and there are likely others.
from message_ix.
Another observation: the linearity is not always true. As an example, take energy intensity of GDP. To compute that at the global level, you need to first aggregate, then derive.
There are numerous different operations required for calculating the global variable. In some cases, for example with capital costs, no value is reported; for prices, we often use the max value and in some cases e.g. for reporting the global price of gas, we actually report the global lng price, therefore requiring a combination of two commodities reported as the same variable; for some variables we will need to calculate using population data i.e. anything that is reported as per capita. Deriving global values is very diverse and what i did is to always recalculate the glb variable in a separate step after calculating regional values.
from message_ix.
Closing; we will centralize continued discussion on #149 and the linked wiki page.
from message_ix.
Related Issues (20)
- Mention Z shell specifics in install instructions HOT 1
- scenario.solve ModelError HOT 10
- Loading Scenarios from Platform gets very slow over time
- ModuleNotFoundError: No module named 'utils' HOT 2
- `type_year="cumulative"` is only populated at `.solve()` HOT 10
- Accidentally openend issue HOT 1
- ModuleNotFoundError: No module named 'utils' HOT 21
- Add `.report.key`
- Plotting functionality should join `historical_activity` to `ACT` HOT 1
- Update install instructions with note about using conda and pip together HOT 2
- LP status (22): dual objective limit exceeded HOT 4
- Ensure westeros_baseline tutorial is consistent with make_westeros
- Create a docs page about 'space'
- Monitor failures in "Install from conda-forge" workflow with pint 0.24
- Web application
- Fix derivation of `price_ref` from `PRICE_EMISSION` HOT 1
- parameter `bound_activity_lo` does not bound `ACT` but `CAP` HOT 7
- Extend historical parameters to track all VAR when shifting `firstmodelyear` HOT 1
- Incomplete identification of "active" technologies.
- Additional dynamic and soft constraints for `total_capacity`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from message_ix.