Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 4 additions & 0 deletions docs/readme/predict.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,3 +85,7 @@ The windows to use for prediction. These windows must be 1,024 bp wide and have
### `-skip_call_peaks, --skip_call_peaks`

This will skip calling peaks at the end of predictions.

### `--threads`

Set number of parallel threads in prediction tasks. If GPUs are used, set this value to be the number of GPUs used for the task. Default: 24.
2 changes: 1 addition & 1 deletion maxatac/analyses/predict.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ def run_prediction(args):
f"Output filename: {outfile_name_bigwig}"
)

with Pool(int(multiprocessing.cpu_count())) as p:
with Pool(args.threads) as p:
forward_strand_predictions = p.starmap(make_stranded_predictions,
[(regions_pool,
args.signal,
Expand Down
6 changes: 6 additions & 0 deletions maxatac/utilities/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,12 @@ def get_parser():
help="Skip calling peaks on prediction tracks"
)

predict_parser.add_argument("--threads",
dest="threads",
type=int,
default=24,
help="Number of processes to run prediction in parallel. Default: 24"
)
#############################################
# Train parser
#############################################
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ def get_description():
]
),
install_requires=[
"tensorflow",
"tensorflow==2.14.0",
"tensorboard",
"biopython",
"py2bit",
Expand Down