Skip to content

Exporter Temporal Alignment #125

@ivanzvonkov

Description

@ivanzvonkov

Context
For each coordinate a time series is generated starting from start_date and ending at end_date. To obtain each time step the current strategy involves incrementing the date by 31. A time series from Jan 2020 to Dec 2021 then looks like this:

Timestep 0: 2021-01-01 -> 2021-02-01
Timestep 1: 2021-02-01 -> 2021-03-04
Timestep 2: 2021-03-04 -> 2021-04-04
Timestep 3: 2021-04-04 -> 2021-05-05
...
Timestep 23: 2022-12-15 -> 2023-01-15

Issue
A time series starting at a different time does not align with this time series. Eg. one starting Jan 2021:

Timestep 0: 2022-01-01 -> 2022-02-01
...
Timestep 11: 2022-12-08 -> 2023-01-08

Potential Solution
This can be addressed by incrementing by month instead of by 31 days.

Relevant code here

cur_end_date = cur_date + timedelta(days=days_per_timestep)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions