Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1028 Reduce export_input_data_county_timeseries #1029

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
ed96ce6
short test example. Reset later
HenrZu May 8, 2024
92e778b
extrapolate function now shorter
HenrZu May 10, 2024
65ad509
adjust example
HenrZu May 10, 2024
cecee21
[ci skip] set up benchmark example
HenrZu May 10, 2024
c0b43af
load static population data only once
HenrZu Jun 24, 2024
9acb873
[ci skip] tests for secir extrapolation, adapt function extrapolation
HenrZu Jun 25, 2024
7055cfa
Merge branch 'main' into 1028-export_input_data_county_timeseries-ret…
HenrZu Jun 25, 2024
95c3d54
add test data
HenrZu Jun 25, 2024
bbb897d
[ci skip] benchmark example
HenrZu Jun 25, 2024
24e580d
add pop manually to load pop data only once
HenrZu Jun 25, 2024
f8d1391
empty extrapolation function if no hdf5
HenrZu Jun 25, 2024
8ebef3c
fix msvc build
HenrZu Jun 26, 2024
0ebaf1c
seperating reading and processing for pop and case data
HenrZu Jun 26, 2024
ddb1122
size_t -> int
HenrZu Jun 26, 2024
2d75114
secir for num_days + 1. More general naming
HenrZu Jun 26, 2024
09ff7b6
same for secir vvs code
HenrZu Jun 26, 2024
99ea23d
[ci skip] size_t to int cast for msvc
HenrZu Jun 26, 2024
8f37800
reset secir ageres example
HenrZu Jun 27, 2024
92cffab
delete old function
HenrZu Jun 27, 2024
113c024
add more tests for input data with old date
HenrZu Jun 27, 2024
5b81f94
some assertions and test old dates
HenrZu Jun 28, 2024
563965d
mock that export data is called
HenrZu Jun 28, 2024
94771df
rm include
HenrZu Jul 1, 2024
36ce480
include gmock
HenrZu Jul 1, 2024
7c48cd4
rm gmock include
HenrZu Jul 2, 2024
d624fad
comment out mock functions
HenrZu Jul 3, 2024
236b741
remove comments from mock class
HenrZu Jul 3, 2024
a1b0037
just mock_method
HenrZu Jul 3, 2024
411f452
add pointer
HenrZu Jul 3, 2024
9ec9550
overwrite export function
HenrZu Jul 3, 2024
14c63b3
rm comments
HenrZu Jul 3, 2024
2731b39
comment out test function
HenrZu Jul 4, 2024
b896839
comment setup
HenrZu Jul 4, 2024
586454f
comment overwrite function
HenrZu Jul 4, 2024
eb5876c
rm mock test because of msvc
HenrZu Jul 5, 2024
58e7cea
test for set_population_data overflow of vacccinated individuals
HenrZu Jul 5, 2024
5a708e0
one more test with no pop data avail
HenrZu Jul 10, 2024
d899aa9
mainly update documentation
HenrZu Aug 15, 2024
6a3385b
rm accumulate age_groups
HenrZu Aug 16, 2024
75a71af
explicit casting, naming
HenrZu Aug 20, 2024
a43a6ea
rm boolean set_vaccination_data
HenrZu Aug 20, 2024
7976337
Test_F in test secir, log level
HenrZu Aug 21, 2024
ba9442f
test value for elegant
HenrZu Aug 21, 2024
3d1c477
Merge branch 'main' into 1028-export_input_data_county_timeseries-ret…
HenrZu Aug 21, 2024
86203d9
type conversation
HenrZu Aug 28, 2024
1db2103
Update cpp/models/ode_secir/parameters_io.h
HenrZu Sep 3, 2024
0ed1db6
some fixes for doc, [in] and [out], del function interpolate_ages
HenrZu Sep 3, 2024
49de116
additional doc
HenrZu Sep 3, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions cpp/models/ode_secir/parameters_io.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
}

IOResult<void> read_confirmed_cases_data(
std::string const& path, std::vector<ConfirmedCasesDataEntry>& rki_data, std::vector<int> const& vregion, Date date,
std::vector<ConfirmedCasesDataEntry>& rki_data, std::vector<int> const& vregion, Date date,
std::vector<std::vector<double>>& vnum_Exposed, std::vector<std::vector<double>>& vnum_InfectedNoSymptoms,
std::vector<std::vector<double>>& vnum_InfectedSymptoms, std::vector<std::vector<double>>& vnum_InfectedSevere,
std::vector<std::vector<double>>& vnum_icu, std::vector<std::vector<double>>& vnum_death,
Expand All @@ -74,12 +74,12 @@
});
if (max_date_entry == rki_data.end()) {
log_error("RKI data file is empty.");
lenaploetzke marked this conversation as resolved.
Show resolved Hide resolved
return failure(StatusCode::InvalidFileFormat, path + ", file is empty.");
return failure(StatusCode::InvalidFileFormat, "RKI file is empty.");

Check warning on line 77 in cpp/models/ode_secir/parameters_io.cpp

View check run for this annotation

Codecov / codecov/patch

cpp/models/ode_secir/parameters_io.cpp#L77

Added line #L77 was not covered by tests
}
auto max_date = max_date_entry->date;
if (max_date < date) {
log_error("Specified date does not exist in RKI data");
return failure(StatusCode::OutOfRange, path + ", specified date does not exist in RKI data.");
return failure(StatusCode::OutOfRange, "Specified date does not exist in RKI data.");

Check warning on line 82 in cpp/models/ode_secir/parameters_io.cpp

View check run for this annotation

Codecov / codecov/patch

cpp/models/ode_secir/parameters_io.cpp#L82

Added line #L82 was not covered by tests
}
auto days_surplus = std::min(get_offset_in_days(max_date, date) - 6, 0);

Expand Down Expand Up @@ -277,4 +277,4 @@

#endif // MEMILIO_HAS_JSONCPP

GCC_CLANG_DIAGNOSTIC(pop)
GCC_CLANG_DIAGNOSTIC(pop)
Loading
Loading