Skip to content

Commit 90e1e5a

Browse files
committed
v0.21.0
1 parent 0d82740 commit 90e1e5a

File tree

4 files changed

+11
-5
lines changed

4 files changed

+11
-5
lines changed

CHANGELOG.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# Changelog
22

3+
## 0.21.0
4+
Assign idx such that it corresponds to the seed used.
5+
36
## 0.20.1
47
Fix saving names: replace `.` by `dot` in the birth-death case.
58

Cargo.lock

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "ecdna-evo"
3-
version = "0.20.1"
3+
version = "0.21.0"
44
edition = "2021"
55
repository = "https://github.com/fraterenz/ecdna-evo"
66
description = "Evolutionary models of extra-chromosomal DNA (ecDNA)"

src/main.rs

+6-3
Original file line numberDiff line numberDiff line change
@@ -244,16 +244,19 @@ fn main() {
244244
}
245245
};
246246
std::process::exit({
247+
// start from seed for the array job
248+
let start = (app.simulation.seed * 10) as usize;
249+
let start_end = start..app.runs + start;
247250
match app.parallel {
248251
Parallel::Debug | Parallel::False => {
249-
(0..app.runs).for_each(my_closure)
252+
(start_end).for_each(my_closure)
250253
}
251-
Parallel::True => (0..app.runs)
254+
Parallel::True => (start_end)
252255
.into_par_iter()
253256
.progress_count(app.runs as u64)
254257
.for_each(my_closure),
255258
}
256-
println!("{} End simulation", Utc::now(),);
259+
println!("{} End simulation", Utc::now());
257260
0
258261
});
259262
}

0 commit comments

Comments
 (0)