|
20 | 20 | },
|
21 | 21 | {
|
22 | 22 | "cell_type": "code",
|
23 |
| - "execution_count": 1, |
| 23 | + "execution_count": null, |
24 | 24 | "id": "3ada4b30",
|
25 | 25 | "metadata": {},
|
26 |
| - "outputs": [ |
27 |
| - { |
28 |
| - "name": "stdout", |
29 |
| - "output_type": "stream", |
30 |
| - "text": [ |
31 |
| - "Environment setup complete\n", |
32 |
| - " Using ETM API at https://beta.engine.energytransitionmodel.com/api/v3\n", |
33 |
| - " Token loaded? True\n", |
34 |
| - "API connection ready\n" |
35 |
| - ] |
36 |
| - } |
37 |
| - ], |
| 26 | + "outputs": [], |
38 | 27 | "source": [
|
39 | 28 | "from example_helpers import setup_notebook\n",
|
40 | 29 | "from pyetm.models import Scenario\n",
|
|
52 | 41 | },
|
53 | 42 | {
|
54 | 43 | "cell_type": "code",
|
55 |
| - "execution_count": 2, |
| 44 | + "execution_count": null, |
56 | 45 | "id": "4770e6a9",
|
57 | 46 | "metadata": {},
|
58 | 47 | "outputs": [],
|
|
77 | 66 | },
|
78 | 67 | {
|
79 | 68 | "cell_type": "code",
|
80 |
| - "execution_count": 6, |
| 69 | + "execution_count": null, |
81 | 70 | "id": "5a1549ac",
|
82 | 71 | "metadata": {},
|
83 |
| - "outputs": [ |
84 |
| - { |
85 |
| - "ename": "ScenarioError", |
86 |
| - "evalue": "Could not update user values: {'external_coupling_industry_chemical_other_burner_crude_oil_share': ['user: Input should be a valid number, unable to parse string as a number']}", |
87 |
| - "output_type": "error", |
88 |
| - "traceback": [ |
89 |
| - "\u001b[31mScenarioError\u001b[39m\u001b[31m:\u001b[39m Could not update user values: {'external_coupling_industry_chemical_other_burner_crude_oil_share': ['user: Input should be a valid number, unable to parse string as a number']}\n" |
90 |
| - ] |
91 |
| - } |
92 |
| - ], |
| 72 | + "outputs": [], |
93 | 73 | "source": [
|
94 | 74 | "scenario.update_user_values({\n",
|
95 | 75 | " \"co_firing_biocoal_share\": 80.0,\n",
|
|
107 | 87 | },
|
108 | 88 | {
|
109 | 89 | "cell_type": "code",
|
110 |
| - "execution_count": 4, |
| 90 | + "execution_count": null, |
111 | 91 | "id": "7fc4dc21",
|
112 | 92 | "metadata": {},
|
113 |
| - "outputs": [ |
114 |
| - { |
115 |
| - "name": "stdout", |
116 |
| - "output_type": "stream", |
117 |
| - "text": [ |
118 |
| - "Area: nl2019\n", |
119 |
| - "End year: 2050\n", |
120 |
| - "Start year: 2019\n", |
121 |
| - "Version: beta\n", |
122 |
| - "Modified inputs: 1\n", |
123 |
| - "First input: co_firing_biocoal_share = 80.0\n" |
124 |
| - ] |
125 |
| - }, |
126 |
| - { |
127 |
| - "ename": "IndexError", |
128 |
| - "evalue": "list index out of range", |
129 |
| - "output_type": "error", |
130 |
| - "traceback": [ |
131 |
| - "\u001b[31mIndexError\u001b[39m\u001b[31m:\u001b[39m list index out of range\n" |
132 |
| - ] |
133 |
| - } |
134 |
| - ], |
| 93 | + "outputs": [], |
135 | 94 | "source": [
|
136 | 95 | "print(f\"Area: {scenario.area_code}\")\n",
|
137 | 96 | "print(f\"End year: {scenario.end_year}\")\n",
|
|
153 | 112 | },
|
154 | 113 | {
|
155 | 114 | "cell_type": "code",
|
156 |
| - "execution_count": 7, |
| 115 | + "execution_count": null, |
157 | 116 | "id": "c6a65f6a",
|
158 | 117 | "metadata": {},
|
159 |
| - "outputs": [ |
160 |
| - { |
161 |
| - "name": "stdout", |
162 |
| - "output_type": "stream", |
163 |
| - "text": [ |
164 |
| - "False\n" |
165 |
| - ] |
166 |
| - } |
167 |
| - ], |
| 118 | + "outputs": [], |
168 | 119 | "source": [
|
169 | 120 | "scenario.update_metadata(\n",
|
170 | 121 | " private= True,\n",
|
|
195 | 146 | },
|
196 | 147 | {
|
197 | 148 | "cell_type": "code",
|
198 |
| - "execution_count": 5, |
| 149 | + "execution_count": null, |
199 | 150 | "id": "98ab2f5c",
|
200 | 151 | "metadata": {},
|
201 |
| - "outputs": [ |
202 |
| - { |
203 |
| - "ename": "AttributeError", |
204 |
| - "evalue": "'Scenario' object has no attribute 'remove_inputs'", |
205 |
| - "output_type": "error", |
206 |
| - "traceback": [ |
207 |
| - "\u001b[31mAttributeError\u001b[39m\u001b[31m:\u001b[39m 'Scenario' object has no attribute 'remove_inputs'\n" |
208 |
| - ] |
209 |
| - } |
210 |
| - ], |
| 152 | + "outputs": [], |
211 | 153 | "source": [
|
212 | 154 | "scenario.remove_user_values([\"co_firing_biocoal_share\"])\n",
|
213 | 155 | "user_vals = scenario.user_values()\n",
|
|
217 | 159 | ],
|
218 | 160 | "metadata": {
|
219 | 161 | "kernelspec": {
|
220 |
| - "display_name": "pyetm-FWBOHxp3", |
| 162 | + "display_name": "pyetm-qKH2ozgc", |
221 | 163 | "language": "python",
|
222 | 164 | "name": "python3"
|
223 | 165 | },
|
|
231 | 173 | "name": "python",
|
232 | 174 | "nbconvert_exporter": "python",
|
233 | 175 | "pygments_lexer": "ipython3",
|
234 |
| - "version": "3.12.11" |
| 176 | + "version": "3.12.9" |
235 | 177 | }
|
236 | 178 | },
|
237 | 179 | "nbformat": 4,
|
|
0 commit comments