Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add override constraining imports into countries or regions #163

Open
timtroendle opened this issue Aug 4, 2021 · 4 comments · May be fixed by #190
Open

Add override constraining imports into countries or regions #163

timtroendle opened this issue Aug 4, 2021 · 4 comments · May be fixed by #190
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@timtroendle
Copy link
Member

Using this override it's possible to model net self-sufficiency of countries or regions. A new configuration parameter determines the sufficiency levels (e.g. a list of 25%, 75%, 100% by default)

A similar override has been used in this article, see the implementation here: https://github.com/timtroendle/geographic-scale/blob/master/src/construct/import_restrictions.py.

@timtroendle timtroendle added the enhancement New feature or request label Aug 4, 2021
@timtroendle timtroendle added this to the 1.1 milestone Aug 4, 2021
@timtroendle
Copy link
Member Author

timtroendle commented Aug 4, 2021

If this should work on the regional level for countries, we will need group constraints (as was used in the original implementation). @brynpickering , group constraints still exist in 0.6.7, right? Would you advice against using them at this point in Calliope's development cycle?

An alternative and simpler implementation could allow net self-sufficiency only on the unit level (i.e. countries on the national level and regions on the regional level). It would not require group constraints. As mentioned by @brynpickering below, this is incorrect. We will need group constraints either way.

@brynpickering
Copy link
Member

We'd need group constraint either way though to limit net import, right?

In terms of development cycle, group constraints will be deprecated from v0.7; they're just too fragile and difficult to test as-is. However, they still exist in v0.6.7 and are (I hope) more robust. I would be fine with sticking with dependence on them for Euro-Calliope <v2.0 as it would fit with the general timeline for v0.7 (earliest end of year).

@timtroendle timtroendle self-assigned this Aug 11, 2021
@timtroendle timtroendle linked a pull request Aug 31, 2021 that will close this issue
5 tasks
@timtroendle
Copy link
Member Author

I took the implementation from https://github.com/timtroendle/geographic-scale and adapted it to the current version. Still I cannot get this to work and I am not quite sure why. I pushed my work in progress into a draft PR and I propose to push this to 1.2 because it requires thorough testing. Any objections, @brynpickering ?

@brynpickering
Copy link
Member

v1.2 works for me. I'll take a look next week at your PR to try and troubleshoot.

@timtroendle timtroendle modified the milestones: 1.1, 1.2 Dec 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants