Skip to content

Conversation

@atmyers
Copy link
Contributor

@atmyers atmyers commented Jan 28, 2025

No description provided.

@tannguyen153
Copy link
Collaborator

Hi @atmyers by default m_unhospToDeath is set to a zero array, so we should see the same results as with the main branch right? I observed some small differences in case and death counts.

@tannguyen153
Copy link
Collaborator

tannguyen153 commented Feb 25, 2025

unless the random number generator gives us a negative value...

@atmyers
Copy link
Contributor Author

atmyers commented Feb 25, 2025

Hi @tannguyen153 - I noticed that too - the answer changes slightly bc the number of random number checks is different now, throwing the exact sequence off.

@stevenhofmeyr
Copy link
Collaborator

I get almost identical results when the unhospCVF is all 0. However, if I set at least one value to 0, I get the following crash:

0::Assertion `mmc[3] == counts[4]' failed, file "/home/shofmeyr/code/ExaEpi/src/main.cpp", line 324 !!!
SIGABRT

Also, I updated the inputs.defaults and how_to_run.rst files.

// determine if agent dies anyway.
if (Random(engine) < disease_parm_d->m_unhospToDeath[age_group_ptr[i]]) {
is_alive_ptr[i] = 0;
flag_status_ptr[i] *= -1;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line need not be here. I don't think it's doing anything (multiplying 0 by -1) but is misleading (flag_status_ptr is used for tracking hospitalized/ICU/vent agents who recover or die).

Comment on lines +126 to +131
// determine if agent dies anyway.
if (Random(engine) < disease_parm_d->m_unhospToDeath[age_group_ptr[i]]) {
is_alive_ptr[i] = 0;
flag_status_ptr[i] *= -1;
status_ptrs[d][i] = Status::dead;
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given that this is the HospitalModel, it may be confusing to have this code here. Why not have it in DiseaseStatus::updateAgents() (using, say a marked_for_death flag similar to marked_for_hosp)?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants