Is your feature request related to a problem? Please describe.
When running with sharrow there is a zone mapping that is applied to turn zone ids into a 0-indexed mapping. At the end of sharrow runs, zone ids are then decoded back to the actual zone ids.
There are cases where a column in an output trip table containing zone ids (e.g. pnr_zone_id) might be -1 or NA. In sharrow, we want to still decode the values that are not -1 (already implemented) or NA (missing).
When decoding a column with NA in there, you get the following error at the end of the model run: pandas.errors.IntCastingNaNError: Cannot convert non-finite values (NA or inf) to integer
Describe the solution you'd like
Add a nullable_nonnegative decode option instead of just a nonnegative option.
Is your feature request related to a problem? Please describe.
When running with sharrow there is a zone mapping that is applied to turn zone ids into a 0-indexed mapping. At the end of sharrow runs, zone ids are then decoded back to the actual zone ids.
There are cases where a column in an output trip table containing zone ids (e.g. pnr_zone_id) might be -1 or NA. In sharrow, we want to still decode the values that are not -1 (already implemented) or NA (missing).
When decoding a column with NA in there, you get the following error at the end of the model run:
pandas.errors.IntCastingNaNError: Cannot convert non-finite values (NA or inf) to integerDescribe the solution you'd like
Add a nullable_nonnegative decode option instead of just a nonnegative option.