Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Chris Jewell
covid19uk
Commits
3dfa160f
Commit
3dfa160f
authored
Jan 05, 2021
by
Chris Jewell
Browse files
Updated utility scripts to incorporate change to Tier data download.
parent
87abe7b1
Changes
4
Hide whitespace changes
Inline
Side-by-side
enqueue_pipeline.sh
View file @
3dfa160f
...
...
@@ -2,9 +2,9 @@
# Enqueues COVID-19 pipelines
CASES_FILE
=
"data/Anonymised Combined Line List 20201
228
.csv"
DATE_LOW
=
"2020-10-0
1
"
DATE_HIGH
=
"202
0-12-25
"
CASES_FILE
=
"data/Anonymised Combined Line List 202
1
01
04
.csv"
DATE_LOW
=
"2020-10-0
9
"
DATE_HIGH
=
"202
1-01-01
"
TEMPLATE_CONFIG
=
template_config.yaml
...
...
@@ -14,7 +14,7 @@ switch-gpu
for
PILLAR
in
both 1
do
for
CASE_DATE_TYPE
in
specimen
report
for
CASE_DATE_TYPE
in
specimen
do
RESULTS_DIR
=
$global_scratch
/covid19/
${
DATE_HIGH
}
_
${
PILLAR
}
_
${
CASE_DATE_TYPE
}
JOB_NAME
=
"covid_
${
DATE_HIGH
}
_
${
PILLAR
}
_
${
CASE_DATE_TYPE
}
"
...
...
prepare_config.py
View file @
3dfa160f
...
...
@@ -58,7 +58,7 @@ for key in ["reported_cases", "commute_volume", "case_date_type", "pillar"]:
config
[
"data"
][
key
]
=
val
if
args
.
inference_period
is
not
None
:
config
[
"
settings
"
][
"inference_period"
]
=
[
str
(
x
)
for
x
in
args
.
inference_period
]
config
[
"
Global
"
][
"inference_period"
]
=
[
str
(
x
)
for
x
in
args
.
inference_period
]
for
key
in
[
"results_dir"
]:
val
=
getattr
(
args
,
key
)
...
...
summary.py
View file @
3dfa160f
...
...
@@ -166,15 +166,11 @@ if __name__ == "__main__":
config
=
yaml
.
load
(
f
,
Loader
=
yaml
.
FullLoader
)
inference_period
=
[
np
.
datetime64
(
x
)
for
x
in
config
[
"
settings
"
][
"inference_period"
]
np
.
datetime64
(
x
)
for
x
in
config
[
"
Global
"
][
"inference_period"
]
]
# Load covariate data
covar_data
=
model_spec
.
read_covariates
(
config
[
"data"
],
date_low
=
inference_period
[
0
],
date_high
=
inference_period
[
1
],
)
covar_data
=
model_spec
.
read_covariates
(
config
)
# Load posterior file
posterior_path
=
os
.
path
.
join
(
...
...
within_between.py
View file @
3dfa160f
...
...
@@ -65,13 +65,11 @@ with open(args.config, "r") as f:
config
=
yaml
.
load
(
f
,
Loader
=
yaml
.
FullLoader
)
inference_period
=
[
np
.
datetime64
(
x
)
for
x
in
config
[
"
settings
"
][
"inference_period"
]
np
.
datetime64
(
x
)
for
x
in
config
[
"
Global
"
][
"inference_period"
]
]
# Load covariate data
covar_data
=
model_spec
.
read_covariates
(
config
[
"data"
],
date_low
=
inference_period
[
0
],
date_high
=
inference_period
[
1
]
)
covar_data
=
model_spec
.
read_covariates
(
config
)
# Load posterior file
posterior
=
h5py
.
File
(
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment