Skip to content

Commit

Permalink
Fix the truthdata output to be missing or Int (#429)
Browse files Browse the repository at this point in the history
  • Loading branch information
SamuelBrand1 authored Aug 16, 2024
1 parent 46344f2 commit aca23b1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pipeline/src/simulate/TruthSimulationConfig.jl
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ function simulate(config::TruthSimulationConfig)
(std = 1.0, cluster_factor = config.cluster_factor,
ϵ_t = config.logit_daily_ascertainment))

y_t = obs_model()
y_t = obs_model() .|> y -> ismissing(y) ? missing : Int(y)

#Return the sampled infections and observations

Expand Down
2 changes: 1 addition & 1 deletion pipeline/test/pipeline/test_pipelinefunctions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
truthdata = fetch.(truthdata_dg_task)

@test length(truthdata) == 1
@test all([data["y_t"] isa Vector{Union{Missing, T}} where {T <: Real}
@test all([data["y_t"] isa Vector{Union{Missing, T}} where {T <: Integer}
for data in truthdata])
end

Expand Down

0 comments on commit aca23b1

Please sign in to comment.