Skip to content

New logging format for number_of_hcw_staff has broken estimate_input_cost_of_scenarios #1839

@sangeetabhatia03

Description

@sangeetabhatia03

The function estimate_input_cost_of_scenarios expects number_of_hcw_staff to logged so that column names look like this: FacilityID_0_Officer_Clinical etc.
Within get_staff_count_by_facid_and_officer_type FacilityID_0_Officer_Clinical is changed to FacilityID=0|Officer=Clinical, which is them passed to unflatten_flattened_multi_index_in_logging.
With the clinics implementation, number_of_hcw_staff is now logged so that each clinic constitutes a column, and the staff count is a dictionary. This change has broken the estimate_input_cost_of_scenarios.

I scanned the scripts directory, and it seems the key is being used only by estimate_input_cost_of_scenarios, but it might affect other analysis files that are not on github.

I've implemented a temporary fix for my analysis, but I am not sure if it might be better to ensure that the healthsystem logging is as close as possible to the old behaviour.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions