Skip to content

Commit 60489ab

Browse files
committed
Expand the NPT specification
1 parent 89313e9 commit 60489ab

4 files changed

Lines changed: 8 additions & 1 deletion

File tree

configs/analysis/inference_analysis_casp.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,4 @@ fault_tolerant: true # whether to continue processing targets if an error occurs
1212
skip_existing: true # whether to skip processing targets for which output already exists
1313
score_relaxed_structures: true # whether to score relaxed structures in addition to the original (unrelaxed) structures
1414
repeat_index: 1 # the run index to use for scoring predictions
15+
no_pretraining: false # whether to score a model without pretraining

configs/model/ensemble_generation.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@ neuralplexer_use_template: true # whether to use the input template protein stru
9696
neuralplexer_separate_pdb: true # whether to separate the predicted protein structures into dedicated PDB files
9797
neuralplexer_rank_outputs_by_confidence: true # whether to rank the output conformations, by default, by ligand confidence (if available) and by protein confidence otherwise
9898
neuralplexer_plddt_ranking_type: ligand # the type of plDDT ranking to apply to generated samples - NOTE: must be one of (`protein`, `ligand`, `protein_ligand`)
99+
neuralplexer_no_pretraining: false # whether to avoid loading pretrained weights
99100
# RoseTTAFold-All-Atom inference arguments:
100101
rfaa_python_exec_path: ${oc.env:PROJECT_ROOT}/forks/RoseTTAFold-All-Atom/RFAA/bin/python3 # the Python executable to use
101102
rfaa_exec_dir: ${oc.env:PROJECT_ROOT}/forks/RoseTTAFold-All-Atom # the RoseTTAFold-All-Atom directory in which to execute the inference scripts

src/analysis/inference_analysis_casp.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,11 @@ def main(cfg: DictConfig):
183183
184184
:param cfg: Configuration dictionary from the hydra YAML file.
185185
"""
186+
if cfg.no_pretraining:
187+
with open_dict(cfg):
188+
cfg.predictions_dir = cfg.predictions_dir.replace(
189+
"_ensemble_predictions", "_npt_ensemble_predictions"
190+
)
186191
if cfg.method == "vina":
187192
with open_dict(cfg):
188193
cfg.predictions_dir = cfg.predictions_dir.replace(

src/models/ensemble_generation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -815,7 +815,7 @@ def get_method_predictions(
815815
elif method == "neuralplexer":
816816
ensemble_benchmarking_output_dir = (
817817
Path(cfg.input_dir if cfg.input_dir else cfg.neuralplexer_out_path).parent
818-
/ f"neuralplexer_{cfg.ensemble_benchmarking_dataset}_outputs_{cfg.ensemble_benchmarking_repeat_index}"
818+
/ f"neuralplexer{'_npt' if cfg.neuralplexer_no_pretraining else ''}_{cfg.ensemble_benchmarking_dataset}_outputs_{cfg.ensemble_benchmarking_repeat_index}"
819819
if cfg.ensemble_benchmarking
820820
else (cfg.input_dir if cfg.input_dir else cfg.neuralplexer_out_path)
821821
)

0 commit comments

Comments
 (0)