Skip to content

Normalizing of exposure rate #1274

@xsaschako

Description

@xsaschako

Motivation / Current Behaviour

   // normalize contact exposure rate by number of people in age groups
        for (auto age_group = AgeGroup(0); age_group < AgeGroup(num_agegroups); age_group++) {
            for (auto& v : cell.m_cached_exposure_rate_contacts.slice(AgeGroup(age_group))) {
                auto number_persons_in_age_group =
                    std::count_if(cell.m_persons.begin(), cell.m_persons.end(), [age_group](observer_ptr<Person> p) {
                        return p->get_age() == age_group;
                    });
                if (number_persons_in_age_group > 0) {
                    v = v / number_persons_in_age_group;
                }
            }
        }

needs to be added

Enhancement description

We need to normalize the exposure rate

Additional context

No response

Checklist

  • Attached labels, especially loc:: or model:: labels.
  • Linked to project

Metadata

Metadata

Assignees

Labels

class::featureA feature to be implemented for some part of the softwareclass::improvementCleanup that doesn't affect functionalityloc::backendThis issue concerns the C++ backend implementation.model::abmThis issue concerns any kind of agent-based model.prio::moderateThe priority of this task is moderate.

Projects

Status

Development 🧑‍💻👩‍💻

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions