policyengine-core 3.3.0__tar.gz → 3.4.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {policyengine_core-3.3.0/policyengine_core.egg-info → policyengine_core-3.4.0}/PKG-INFO +1 -1
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data/dataset.py +2 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/reforms/reform.py +2 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/simulation.py +52 -16
- {policyengine_core-3.3.0 → policyengine_core-3.4.0/policyengine_core.egg-info}/PKG-INFO +1 -1
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/setup.py +1 -1
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/LICENSE +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/MANIFEST.in +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/README.md +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/charts/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/charts/api.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/charts/bar.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/charts/formatting.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/commons/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/commons/formulas.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/commons/misc.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/commons/rates.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/constants.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/data/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/data/datasets/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/data/datasets/country_template_dataset.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/entities.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/modelled_policies.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/parameters/benefits/basic_income.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/parameters/benefits/housing_allowance.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/parameters/benefits/index.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/parameters/benefits/parenting_allowance/amount.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/parameters/benefits/parenting_allowance/income_threshold.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/parameters/general/age_of_majority.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/parameters/general/age_of_retirement.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/parameters/taxes/housing_tax.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/parameters/taxes/income_tax_rate.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/parameters/taxes/social_security_contribution.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/reforms/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/reforms/add_dynamic_variable.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/reforms/add_new_tax.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/reforms/flat_social_security_contribution.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/reforms/modify_social_security_taxation.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/reforms/removal_basic_income.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/situation_examples/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/situation_examples/couple.json +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/situation_examples/housing.json +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/situation_examples/single.json +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/age.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/basic_income.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/disposable_income.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/housing_allowance.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/housing_tax.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/income_tax.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/reforms/add_dynamic_variable.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/reforms/add_new_tax.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/reforms/modify_social_security_taxation.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/situations/income_tax.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/situations/parenting_allowance.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/social_security_contribution.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/tests/test_microsimulation.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/variables/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/variables/benefits.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/variables/demographics.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/variables/housing.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/variables/ids.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/variables/income.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/variables/stats.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/variables/taxes.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_storage/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_storage/in_memory_storage.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_storage/on_disk_storage.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_structures/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_structures/parameter_metadata.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_structures/parameter_node_metadata.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_structures/reference.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_structures/unit.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/entities/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/entities/entity.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/entities/group_entity.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/entities/helpers.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/entities/role.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/enums/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/enums/config.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/enums/enum.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/enums/enum_array.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/cycle_error.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/empty_argument_error.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/nan_creation_error.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/parameter_not_found_error.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/parameter_parsing_error.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/period_mismatch_error.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/situation_parsing_error.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/spiral_error.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/variable_name_conflict_error.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/variable_not_found_error.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/experimental/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/experimental/memory_config.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/extension_template/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/extension_template/local_benefit.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/extension_template/parameters/local_town/child_allowance/amount.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/extension_template/parameters/local_town/child_allowance/index.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/extension_template/parameters/local_town/index.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/extension_template/tests/local_benefit.yaml +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/holders/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/holders/helpers.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/holders/holder.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/model_api.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/at_instant_like.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/config.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/helpers.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/operations/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/operations/get_parameter.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/operations/homogenize_parameters.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/operations/interpolate_parameters.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/operations/propagate_parameter_metadata.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/operations/uprate_parameters.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/parameter.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/parameter_at_instant.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/parameter_node.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/parameter_node_at_instant.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/parameter_scale.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/parameter_scale_bracket.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/vectorial_parameter_node_at_instant.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/periods/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/periods/config.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/periods/helpers.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/periods/instant_.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/periods/period_.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/populations/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/populations/config.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/populations/group_population.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/populations/population.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/projectors/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/projectors/entity_to_person_projector.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/projectors/first_person_to_entity_projector.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/projectors/helpers.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/projectors/projector.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/projectors/unique_role_to_entity_projector.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/reforms/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/scripts/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/scripts/assets/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/scripts/assets/index.html +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/scripts/policyengine_command.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/scripts/run_data.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/scripts/run_test.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/scripts/simulation_generator.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/helpers.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/individual_sim.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/microsimulation.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/simulation_builder.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxbenefitsystems/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxbenefitsystems/tax_benefit_system.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/abstract_rate_tax_scale.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/abstract_tax_scale.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/amount_tax_scale_like.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/helpers.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/linear_average_rate_tax_scale.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/marginal_amount_tax_scale.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/marginal_rate_tax_scale.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/rate_tax_scale_like.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/single_amount_tax_scale.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/tax_scale_like.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tools/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tools/simulation_dumper.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tools/test_from_situation.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tools/test_runner.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/computation_log.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/flat_trace.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/full_tracer.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/performance_log.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/simple_tracer.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/trace_node.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/tracing_parameter_node_at_instant.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/variable_graph.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/types/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/types/data_types/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/types/data_types/arrays.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/variables/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/variables/config.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/variables/defined_for.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/variables/helpers.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/variables/typing.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/variables/variable.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/warnings/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/warnings/libyaml_warning.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/warnings/memory_config_warning.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/warnings/tempfile_warning.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/weighting/__init__.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/weighting/microdf.py +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core.egg-info/SOURCES.txt +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core.egg-info/dependency_links.txt +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core.egg-info/entry_points.txt +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core.egg-info/requires.txt +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core.egg-info/top_level.txt +0 -0
- {policyengine_core-3.3.0 → policyengine_core-3.4.0}/setup.cfg +0 -0
|
@@ -148,6 +148,8 @@ class Reform(TaxBenefitSystem):
|
|
|
148
148
|
for period, value in period_values.items():
|
|
149
149
|
if "." in period:
|
|
150
150
|
start, stop = period.split(".")
|
|
151
|
+
start = instant_(start)
|
|
152
|
+
stop = instant_(stop)
|
|
151
153
|
parameter.update(
|
|
152
154
|
start=start, stop=stop, value=value
|
|
153
155
|
)
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/simulation.py
RENAMED
|
@@ -250,22 +250,32 @@ class Simulation:
|
|
|
250
250
|
) from e
|
|
251
251
|
|
|
252
252
|
if self.dataset.data_format == Dataset.FLAT_FILE:
|
|
253
|
+
data_copy = {col: data[col].values for col in data.copy().columns}
|
|
253
254
|
data = {col: data[col].values for col in data.columns}
|
|
254
255
|
|
|
255
256
|
person_entity = self.tax_benefit_system.person_entity
|
|
256
257
|
entity_id_field = f"{person_entity.key}_id"
|
|
258
|
+
|
|
259
|
+
def get_eternity_array(name):
|
|
260
|
+
if self.dataset.data_format == Dataset.FLAT_FILE:
|
|
261
|
+
# Look for any column with variablename__timeperiod
|
|
262
|
+
for col in data:
|
|
263
|
+
if col.split("__")[0] == name:
|
|
264
|
+
return data[col]
|
|
265
|
+
elif self.dataset.data_format == Dataset.TIME_PERIOD_ARRAYS:
|
|
266
|
+
return data[name][list(data[name].keys())[0]]
|
|
267
|
+
return data[name]
|
|
268
|
+
|
|
257
269
|
if self.dataset.data_format != Dataset.FLAT_FILE:
|
|
258
270
|
assert (
|
|
259
271
|
entity_id_field in data
|
|
260
272
|
), f"Missing {entity_id_field} column in the dataset. Each person entity must have an ID array defined for ETERNITY."
|
|
261
273
|
elif entity_id_field not in data:
|
|
262
|
-
data[entity_id_field] = np.arange(
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
)
|
|
268
|
-
entity_ids = get_eternity_array(data[entity_id_field])
|
|
274
|
+
data[entity_id_field] = np.arange(
|
|
275
|
+
len(get_eternity_array("person_id"))
|
|
276
|
+
)
|
|
277
|
+
|
|
278
|
+
entity_ids = get_eternity_array(entity_id_field)
|
|
269
279
|
builder.declare_person_entity(person_entity.key, entity_ids)
|
|
270
280
|
|
|
271
281
|
for group_entity in self.tax_benefit_system.group_entities:
|
|
@@ -274,15 +284,18 @@ class Simulation:
|
|
|
274
284
|
assert (
|
|
275
285
|
entity_id_field in data
|
|
276
286
|
), f"Missing {entity_id_field} column in the dataset. Each group entity must have an ID array defined for ETERNITY."
|
|
287
|
+
entity_ids = get_eternity_array(entity_id_field)
|
|
277
288
|
elif entity_id_field not in data:
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
289
|
+
entity_id_field_values = get_eternity_array(
|
|
290
|
+
f"person_{group_entity.key}_id"
|
|
291
|
+
)
|
|
292
|
+
if entity_id_field_values is not None:
|
|
293
|
+
entity_ids = np.arange(
|
|
294
|
+
len(np.unique(entity_id_field_values))
|
|
281
295
|
)
|
|
282
296
|
else:
|
|
283
|
-
|
|
297
|
+
entity_ids = np.arange(len(data[list(data.keys())[0]]))
|
|
284
298
|
|
|
285
|
-
entity_ids = get_eternity_array(data[entity_id_field])
|
|
286
299
|
builder.declare_entity(group_entity.key, entity_ids)
|
|
287
300
|
|
|
288
301
|
person_membership_id_field = (
|
|
@@ -295,14 +308,14 @@ class Simulation:
|
|
|
295
308
|
elif person_membership_id_field not in data:
|
|
296
309
|
data[person_membership_id_field] = np.arange(len(data))
|
|
297
310
|
person_membership_ids = get_eternity_array(
|
|
298
|
-
|
|
311
|
+
person_membership_id_field
|
|
299
312
|
)
|
|
300
313
|
|
|
301
314
|
person_role_field = f"{person_entity.key}_{group_entity.key}_role"
|
|
302
315
|
if person_role_field in data:
|
|
303
|
-
person_roles = get_eternity_array(
|
|
316
|
+
person_roles = get_eternity_array(person_role_field)
|
|
304
317
|
elif "role" in data:
|
|
305
|
-
person_roles = get_eternity_array(
|
|
318
|
+
person_roles = get_eternity_array("role")
|
|
306
319
|
elif self.default_role is not None:
|
|
307
320
|
person_roles = np.full(len(entity_ids), self.default_role)
|
|
308
321
|
else:
|
|
@@ -317,6 +330,10 @@ class Simulation:
|
|
|
317
330
|
|
|
318
331
|
self.build_from_populations(builder.populations)
|
|
319
332
|
|
|
333
|
+
if self.dataset.data_format == Dataset.FLAT_FILE:
|
|
334
|
+
# Ensure we're back to all person-level data.
|
|
335
|
+
data = data_copy
|
|
336
|
+
|
|
320
337
|
if self.dataset.data_format != Dataset.FLAT_FILE:
|
|
321
338
|
for variable in data:
|
|
322
339
|
if variable in self.tax_benefit_system.variables:
|
|
@@ -362,7 +379,7 @@ class Simulation:
|
|
|
362
379
|
else:
|
|
363
380
|
entity_level_data = data[variable]
|
|
364
381
|
|
|
365
|
-
self.set_input(
|
|
382
|
+
self.set_input(variable_name, time_period, entity_level_data)
|
|
366
383
|
|
|
367
384
|
self.default_calculation_period = (
|
|
368
385
|
self.dataset.time_period or self.default_calculation_period
|
|
@@ -1453,6 +1470,25 @@ class Simulation:
|
|
|
1453
1470
|
with h5py.File(cache_file_path, "w") as f:
|
|
1454
1471
|
f.create_dataset("values", data=value)
|
|
1455
1472
|
|
|
1473
|
+
def to_input_dataframe(
|
|
1474
|
+
self,
|
|
1475
|
+
) -> pd.DataFrame:
|
|
1476
|
+
"""Exports a DataFrame which can be loaded back to a new Simulation to reproduce the same results.
|
|
1477
|
+
|
|
1478
|
+
Returns:
|
|
1479
|
+
pd.DataFrame: The DataFrame containing the input values.
|
|
1480
|
+
"""
|
|
1481
|
+
|
|
1482
|
+
df = pd.DataFrame()
|
|
1483
|
+
|
|
1484
|
+
for variable in self.tax_benefit_system.variables:
|
|
1485
|
+
for period in self.get_holder(variable).get_known_periods():
|
|
1486
|
+
values = self.calculate(variable, period, map_to="person")
|
|
1487
|
+
if values is not None:
|
|
1488
|
+
df[f"{variable}__{period}"] = values
|
|
1489
|
+
|
|
1490
|
+
return df
|
|
1491
|
+
|
|
1456
1492
|
|
|
1457
1493
|
class NpEncoder(json.JSONEncoder):
|
|
1458
1494
|
def default(self, obj):
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/__init__.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/constants.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/country_template/entities.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_storage/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_structures/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_structures/reference.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/data_structures/unit.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/entities/group_entity.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/empty_argument_error.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/nan_creation_error.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/errors/spiral_error.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/experimental/__init__.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/experimental/memory_config.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/extension_template/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/__init__.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/at_instant_like.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/parameter.py
RENAMED
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/parameter_node.py
RENAMED
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/parameters/parameter_scale.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/populations/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/populations/population.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/projectors/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/projectors/projector.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/scripts/assets/__init__.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/scripts/assets/index.html
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/__init__.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/helpers.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/individual_sim.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/simulations/microsimulation.py
RENAMED
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxbenefitsystems/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/taxscales/tax_scale_like.py
RENAMED
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tools/simulation_dumper.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tools/test_from_situation.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/computation_log.py
RENAMED
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/full_tracer.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/performance_log.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/simple_tracer.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/tracers/variable_graph.py
RENAMED
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/types/data_types/__init__.py
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/types/data_types/arrays.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/variables/defined_for.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/warnings/libyaml_warning.py
RENAMED
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core/warnings/tempfile_warning.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core.egg-info/entry_points.txt
RENAMED
|
File without changes
|
|
File without changes
|
{policyengine_core-3.3.0 → policyengine_core-3.4.0}/policyengine_core.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|