-
Notifications
You must be signed in to change notification settings - Fork 0
/
InputCircularInterventionshybrid.py
67 lines (53 loc) · 2.36 KB
/
InputCircularInterventionshybrid.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
# -*- coding: utf-8 -*-
"""
Created on Tue Apr 16 14:38:03 2024
@author: regin
"""
import mario
from mario import slicer, parse_exiobase_3
import pandas as pd
# %%
Material = "Steel" # change to focus on material of interest
Resource = "Iron ores"
Material2 = "Aluminium"
Resource2 = "Bauxite and aluminium ores"
regionlock = False #nl and rest of the world
regionlock2 = True # bigger regions in the world
sectorlock = True # arbitary sector combinations
# #%%
# #hiot_path = r"C:/Industrial_ecology/Thesis/IOT_2021_ixi"
# hiot_path = r'C:/Industrial_ecology/Thesis/Circularinterventions/Data/data_hiot'
# save_path = r"C:/Industrial_ecology/Thesis/Circularinterventions/Data"
# #world_HIOT = parse_exiobase_3(path=iot_path, version='3.8.1')
# #world_IOT.get_shock_excel(path=save_path)
# world_hiot = mario.hybrid_sut_exiobase(path = hiot_path)
# save_path = r'HIOTshock_iot.xlsx'
# world_hiot.get_shock_excel(path=save_path)
#%%
extensions = pd.ExcelFile("C:/Industrial_ecology/Thesis/Circularinterventions/Data/MR_HIOT_2011_v3_3_18_extensions.xlsx""")
extensions.sheet_names
# Resource extraction matrix of Z
RE = extensions.parse(sheet_name="resource_act", index_col=[0,1], header=[0,1,2,3])
# Resource extraction matrix of Y
RE_FD = extensions.parse(sheet_name="resource_FD", index_col=[0,1], header=[0,1,2,3])
# Waste supply matrix of Z
WS = extensions.parse(sheet_name="waste_sup_act", index_col=[0,1], header=[0,1,2,3])
# Waste supply matrix of Y
WS_FD = extensions.parse(sheet_name="waste_sup_FD", index_col=[0,1], header=[0,1,2,3])
# Waste use matrix of Z
WU = extensions.parse(sheet_name="waste_use_act", index_col=[0,1], header=[0,1,2,3])
# Waste use matrix of Y => This is all 0's so it can also be ignored
WU_FD = extensions.parse(sheet_name="waste_use_FD", index_col=[0,1], header=[0,1,2,3])
#%%
# Stock addition matrix of Z
SA = extensions.parse(sheet_name="stock_addition_act", index_col=[0,1], header=[0,1,2,3])
# Stock addition matrix of Y
SA_FD = extensions.parse(sheet_name="stock_addition_fd", index_col=[0,1], header=[0,1,2,3])
#%%
# Stock depletion matrix
SD = extensions.parse(sheet_name="waste_from_stocks", index_col=[0,1], header=[0,1,2,3])
#%%
EM = extensions.parse(sheet_name="Emiss_act", index_col=[0,1,2], header=[0,1,2,3])
EM_FD = extensions.parse(sheet_name="Emiss_FD", index_col=[0,1,2], header=[0,1,2,3])
print(WU.NL.loc[Material])
print(RE.loc[Resource])