Skip to content

Commit

Permalink
offset_preprocessing for pipeline load
Browse files Browse the repository at this point in the history
  • Loading branch information
jpn-- committed Jun 14, 2022
1 parent 242f0d1 commit 736def4
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions activitysim/core/pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -425,6 +425,14 @@ def load_checkpoint(checkpoint_name):
# register it as an orca table
rewrap(table_name, df)
loaded_tables[table_name] = df
if table_name == 'land_use' and '_original_zone_id' in df.columns:
# The presence of _original_zone_id indicates this table index was
# decoded to zero-based, so we need to disable offset
# processing for legacy skim access.
# TODO: this "magic" column name should be replaced with a mechanism
# to write and recover particular settings from the pipeline
# store, but we don't have that mechanism yet
config.override_setting("offset_preprocessing", True)

# register for tracing in order that tracing.register_traceable_table wants us to register them
traceable_tables = inject.get_injectable("traceable_tables", [])
Expand Down

0 comments on commit 736def4

Please sign in to comment.