Skip to content

Commit

Permalink
Added logging + unknown geographies
Browse files Browse the repository at this point in the history
  • Loading branch information
romainsacchi committed Nov 3, 2023
1 parent caaeefc commit 0c38b09
Show file tree
Hide file tree
Showing 6 changed files with 270 additions and 225 deletions.
13 changes: 13 additions & 0 deletions premise/data/utils/logging/logconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,14 @@ handlers:
formatter: simple
mode: w

file_metal:
class: logging.FileHandler
level: INFO
filename: "export/logs/premise_metal.log"
encoding: utf8
formatter: simple
mode: w

file_cement:
class: logging.FileHandler
level: INFO
Expand Down Expand Up @@ -80,6 +88,11 @@ loggers:
handlers: [ file_steel ]
propagate: False

metal:
level: INFO
handlers: [ file_metal ]
propagate: False

cement:
level: INFO
handlers: [ file_cement ]
Expand Down
39 changes: 39 additions & 0 deletions premise/data/utils/logging/reporting.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,45 @@ premise_steel:
unit: 0-1
tab: Steel

premise_metal:
columns:
timestamp:
name: timestamp
description: Timestamp of the log entry
module:
name: module
description: Module name
level:
name: level
description: Log level
status:
name: status
description: Status of the dataset
model:
name: model
description: IAM model name
pathway:
name: pathway
description: Pathway name
year:
name: year
description: Year
dataset:
name: dataset
description: Dataset name
product:
name: reference product
description: Product
region:
name: region
description: Region name
post-allocation correction:
name: Post-allocation correction
description: Correction factor applied to the initial amount of metal produced
unit: kilogram

tab: Metal

premise_cement:
columns:
timestamp:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -218,4 +218,58 @@ CN-NECG:
remind: CHA
image: CHN
message: CHN
tiam: CHI
tiam: CHI
LA: # Laos
remind: OAS
image: SEAS
message: PAS
tiam: ODA

# Fiji
FJ:
remind: OAS
image: SEAS
message: PAS
tiam: ODA

# Guinea
GN:
remind: SSA
image: RSAF
message: AFR
tiam: AFR

# Guyana
GY:
remind: LAM
image: RSAM
message: LAM
tiam: CSA

# Sierra Leone
SL:
remind: SSA
image: RSAF
message: AFR
tiam: AFR

# add Solomon Islands
SB:
remind: OAS
image: SEAS
message: PAS
tiam: ODA

# add Uganda
UG:
remind: SSA
image: RSAF
message: AFR
tiam: AFR

# add Afghanistan
AF:
remind: OAS
image: SEAS
message: PAS
tiam: ODA
Loading

0 comments on commit 0c38b09

Please sign in to comment.