-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create run_testmode_pipeline.jl (#359)
* Create run_testmode_pipeline.jl * Fix inference prefixing along with a method refactor * QUICKFIX: remove dagger spawn at top level of pipeline
- Loading branch information
1 parent
7bf2726
commit 4dfdfad
Showing
4 changed files
with
63 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# Local environment script to run the analysis pipeline | ||
using Pkg | ||
Pkg.activate(joinpath(@__DIR__(), "..")) | ||
using Dagger | ||
|
||
@assert !isempty(ARGS) "Test mode script requires the number of draws as an argument." | ||
ndraws = parse(Int64, ARGS[1]) | ||
|
||
@info(""" | ||
Running the analysis pipeline in test mode with $(ndraws) draws per model. | ||
-------------------------------------------- | ||
""") | ||
|
||
# Define the backend resources to use for the pipeline | ||
# in this case we are using distributed local workers with loaded modules | ||
using Distributed | ||
pids = addprocs(; exeflags = ["--project=$(Base.active_project())"]) | ||
|
||
@everywhere using EpiAwarePipeline | ||
|
||
# Create an instance of the pipeline behaviour | ||
|
||
pipelines = [ | ||
SmoothOutbreakPipeline(ndraws = ndraws), MeasuresOutbreakPipeline(ndraws = ndraws), | ||
SmoothEndemicPipeline(ndraws = ndraws), RoughEndemicPipeline(ndraws = ndraws)] | ||
|
||
# Run the pipeline | ||
do_pipeline(pipelines) | ||
|
||
# Remove the workers | ||
rmprocs(pids) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters