Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
af2-at-scicore
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
schwede
af2-at-scicore
Commits
3aa8bdb1
Commit
3aa8bdb1
authored
3 years ago
by
Bienchen
Browse files
Options
Downloads
Patches
Plain Diff
Add option --num-multimer-predictions-per-model
parent
6a14f8a0
Branches
Branches containing commit
Tags
4.0.2
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
CHANGELOG.md
+8
-0
8 additions, 0 deletions
CHANGELOG.md
run_af2/src/run_af2/_shared.py
+19
-1
19 additions, 1 deletion
run_af2/src/run_af2/_shared.py
run_af2/src/run_af2/run_singularity.py
+13
-1
13 additions, 1 deletion
run_af2/src/run_af2/run_singularity.py
with
40 additions
and
2 deletions
CHANGELOG.md
+
8
−
0
View file @
3aa8bdb1
Changes in Release 3.1.0
=================================================================================
*
`run_af2`
Python package:
*
Add command line option
`--num-multimer-predictions-per-model`
*
Switch default value of option
`--use-gpu-relax`
to False
Changes in Release 3.0.0
=================================================================================
...
...
This diff is collapsed.
Click to expand it.
run_af2/src/run_af2/_shared.py
+
19
−
1
View file @
3aa8bdb1
...
...
@@ -128,7 +128,15 @@ def parse_af2_arguments(parser):
"
--use-gpu-relax
"
,
action
=
"
store_true
"
,
help
=
"
Use GPU for relaxation (if GPU is enabled).
"
,
default
=
True
,
default
=
False
,
)
af2_group
.
add_argument
(
"
--num-multimer-predictions-per-model
"
,
type
=
int
,
help
=
"
Number of models per prediction. Only applies with
"
+
"
--model-preset=multimer.
"
,
metavar
=
"
<NUMBER>
"
,
default
=
5
,
)
af2_group
.
add_argument
(
"
--version
"
,
...
...
@@ -244,6 +252,16 @@ def parse_af2_arguments(parser):
flush
=
True
,
)
# check that --use-gpu-relax is only enabled together with --use-gpu
if
opts
.
use_gpu_relax
and
not
opts
.
use_gpu
:
print
(
"
WARNING: Enabling --use-gpu-relax on non-gpu compute nodes
"
+
"
will fail. You are seeing this warning since you enabled
"
+
"
--use-gpu-relax but not --use-gpu.
"
,
file
=
sys
.
stderr
,
flush
=
True
,
)
if
opts
.
singularity_image
is
not
None
:
if
not
os
.
path
.
exists
(
opts
.
singularity_image
):
print
(
...
...
This diff is collapsed.
Click to expand it.
run_af2/src/run_af2/run_singularity.py
+
13
−
1
View file @
3aa8bdb1
...
...
@@ -119,6 +119,7 @@ def _assemble_singularity_call( # pylint: disable=too-many-arguments
use_precomputed_msas
,
no_run_relax
,
use_gpu_relax
,
num_multimer_predictions_per_model
,
data_paths
,
extra_arg_list
,
):
...
...
@@ -152,6 +153,8 @@ def _assemble_singularity_call( # pylint: disable=too-many-arguments
f
"
--max_template_date=
{
max_template_date
}
"
,
f
"
--db_preset=
{
db_preset
}
"
,
f
"
--model_preset=
{
model_preset
}
"
,
"
--num_multimer_predictions_per_model=
"
+
f
"
{
num_multimer_predictions_per_model
}
"
,
"
--logtostderr
"
,
]
)
...
...
@@ -207,7 +210,8 @@ def run_af2_singularity_image( # pylint: disable=too-many-arguments
model_preset
=
"
monomer
"
,
use_precomputed_msas
=
False
,
no_run_relax
=
False
,
use_gpu_relax
=
True
,
use_gpu_relax
=
False
,
num_multimer_predictions_per_model
=
5
,
af2_image_file
=
None
,
# af2_image_dir="/export/soft/singularity-containers/alphafold",
af2_image_dir
=
"
/scicore/home/schwede/GROUP/alphafold_data/
"
,
...
...
@@ -280,6 +284,12 @@ def run_af2_singularity_image( # pylint: disable=too-many-arguments
:param use_gpu_relax: Run relaxation on GPU. Corresponds to the
use_gpu_relax parameter in AF2.
:type use_gpu_relax: :class:`bool`
:param num_multimer_predictions_per_model: In multimer mode, no. of
predictions per model.
Corresponds to the
num_multimer_predictions_per_model
parameter in AF2.
:type num_multimer_predictions_per_model: :class:`int`
:param af2_image_file: Declare a Singularity image to run the AF2 pipeline
from. If None, an image from af2_image_dir will be
used.
...
...
@@ -410,6 +420,7 @@ def run_af2_singularity_image( # pylint: disable=too-many-arguments
use_precomputed_msas
,
no_run_relax
,
use_gpu_relax
,
num_multimer_predictions_per_model
,
data_paths
,
extra_arg_list
,
)
...
...
@@ -481,6 +492,7 @@ def main():
opts
.
use_precomputed_msas
,
opts
.
no_run_relax
,
opts
.
use_gpu_relax
,
opts
.
num_multimer_predictions_per_model
,
opts
.
singularity_image
,
extra_arg_list
=
extra_arg_list
,
**
data_paths
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment