Skip to content

Create an --all_structs flag for populate_modelcif.py, capture *every* model & seed #622

Description

@keiran-rowell-unsw

Was discussed in the SBF facility meeting. Since the pipeline already emits the best predicted structure in top_ranked_structures by default, it that separateness of "rank_0" as the "best" predicted structure should be preserved.

However, it is also helpful to have a single .mmcif files to share with colleagues that has all atomic data of the Assembly without having to re-spec everything about the model run in separate files.

This is provided by .model.Model

Since I learnt how to implement flags with --write_binary to implement #583, should also include a --all_structs with default presence boolean False (action='store_true' in argparse)

EDIT: implemented with fixed rank_{0..4} rather than a glob because nextflow shell parsing was causing issues. Will validate in real-pipeline that structure globbing is being passed (and rejected) properly by:

    if all_structs:
        for struct_file in struct_files:
            try:
                biopy_struct = _parse_structure(struct_file)
            except Exception as err:
                print(
                    f"Skipping unparseable structure file {struct_file}: {err}",
                    file=sys.stderr,
                )
                continue
            selected_struct_files.append(struct_file)
            biopy_structs.append(biopy_struct)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions