Skip to content

Commit

Permalink
fix: some package names + move blosum to optional
Browse files Browse the repository at this point in the history
  • Loading branch information
elkoz committed Nov 15, 2023
1 parent d146afa commit 6835a5a
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 10 deletions.
10 changes: 7 additions & 3 deletions .conda/arm64/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ requirements:
- Biopython==1.79
- click>=8.1.3
- biopandas>=0.4.1
- boto3==1.24.59
- boto3
- p-tqdm
- networkx==2.8.8
- einops
Expand All @@ -41,8 +41,12 @@ requirements:
- awscli==1.25.60
- bs4
- rcsbsearch
- tmtools
- fair-esm
- pyyaml
- rdkit
- pypdb
- prody



about:
home: https://github.com/adaptyvbio/ProteinFlow
Expand Down
2 changes: 1 addition & 1 deletion proteinflow/data/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1993,7 +1993,7 @@ def align_structure(self, reference_pdb_path, save_pdb_path, chain_ids=None):
io.save(save_pdb_path)

@staticmethod
@requires_extra("mda", install_name="MDAnalysis")
@requires_extra("MDAnalysis")
def combine_multiple_frames(files, output_path="combined.pdb"):
"""Combine multiple PDB files into a single multiframe PDB file.
Expand Down
10 changes: 6 additions & 4 deletions proteinflow/metrics/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,17 @@
import os

import biotite.structure.io as bsio
import blosum as bl
import numpy as np
import torch
from torch.nn import functional as F
from tqdm import tqdm

from proteinflow.extra import requires_extra

try:
import blosum as bl
except ImportError:
pass
try:
import esm
except ImportError:
Expand All @@ -33,6 +36,7 @@
pass


@requires_extra("blosum")
def blosum62_score(seq_before, seq_after):
"""Calculate the BLOSUM62 score between two sequences.
Expand Down Expand Up @@ -264,9 +268,7 @@ def tm_score(coordinates1, coordinates2, sequence1, sequence2):
return (res.tm_norm_chain1 + res.tm_norm_chain2) / 2


requires_extra("esm", install_name="fair-esm[esmfold]")


@requires_extra("esm", install_name="fair-esm[esmfold]")
def esmfold_generate(sequences, filepaths=None):
"""Generate PDB structures using ESMFold.
Expand Down
3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,9 @@ dependencies = [
"bs4>=0.0.1",
"pyyaml>=6",
"rcsbsearch",
"blosum>=2.0",
"pre-commit",
"rdkit",
"pypdb",
"prody",
"joblib",
]
keywords = ["bioinformatics", "dataset", "protein", "PDB", "deep learning", "antibody"]
Expand All @@ -52,6 +50,7 @@ processing = [
"ablang",
"igfold",
"immunebuilder",
"blosum>=2.0",
]

[tool.setuptools.packages]
Expand Down

0 comments on commit 6835a5a

Please sign in to comment.