GithubHelp home page GithubHelp logo

tyang816 / protssn Goto Github PK

View Code? Open in Web Editor NEW
41.0 41.0 3.0 33.92 MB

Fusion of protein sequence and structural information, using denoising pre-training network for protein engineering (zero-shot).

License: MIT License

Python 98.97% Shell 1.03%
directed-evolution graph-neural-networks mutant-prediction protein protein-engineering protein-structure zero-shot

protssn's People

Contributors

tyang816 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

protssn's Issues

mean_attr.pt是怎么来的

您好,我想了解一下文件src\utils\dataset_utils里面的dataset_argument_、NormalizeProtein以及get_stat函数,尤其是后面两个。里面提到了一个mean_attr.pt 文件。我想知道的是这个文件是怎么来的呢?不同的dataset用的是一样的吗?可以帮忙解释一下吗?
谢谢!

Inputs during training and inference

Hi,

Excellent work! I am reading ProtSSN and trying to use it, but I have a few questions:

  1. The input in downstream tasks is the entire protein, while the training set uses CATH domains. How does this difference affect the model's performance?
  2. The model's inputs during training are crystal structures, but AF2 or ESM2 predicted structures are used for inference. How much bias does this introduce?
  3. If I want to use ProtSSN for downstream tasks, do I just use the code provided in README to extract embeddings?

Congratulations again on your work!

Best regards

get_node_features函数中二面角phi计算好像不对

你好呀,看起来src.dataset.mutant_dataset.py 中第318行angles[i, 0] = dihedral(c_coords[i], n_coords[i], c_alpha_coords[i], n_coords[i+1])不对。
image

感觉正确的计算方式应该是 C(i-1)-N(i)-Cα(i)-C(i),可以参考西湖大学反转结构算法PIFold的结构特征编码方式(应该更高效)。不过既然这两都是角度特征且不涉及精确的原子坐标计算,对最终结果的影响应该不大。

torch_geometric version

Hi,

Thanks for your code, and model.

Just a freindly notice, it seems that torch_geometric update some functions. The function "propagate" in the egnn_pytorch_geometric.py file doesn't work properly, and have an error message: "too many values to unpack (expected 2)".

I got this error when I used version 2.5.2, but your code worked well after downgrade to 2.3.0.

Best,
Yuxuan

AssertionError

python zeroshot_predict.py --gnn_model_name k20_h512 --mutant_dataset_dir data/mutant_example/no_exp --result_dir result/no_exp

--------------- ProtSSN k20_h512 ---------------
Processing...
Processing A0A5J4FAY1_MICAE: 100%|████████████████████████████████████████████████████████| 1/1 [00:02<00:00, 2.10s/it]
Total proteins: ['A0A5J4FAY1_MICAE']
Wrong proteins: []
Processing A0A5J4FAY1_MICAE.pt: 100%|█████████████████████████████████████████████████████| 1/1 [00:00<00:00, 61.59it/s]
Done!

Protein names: ['A0A5J4FAY1_MICAE']
Number of proteins: 1
k20_h512 Number of trainable parameter: 148.10M
Traceback (most recent call last):
File "/home/structure/ProtSSN-master/zeroshot_predict.py", line 183, in
predict(args=args, plm_model=plm_model, gnn_model=gnn_model, loader=mutant_loader)
File "/home/structure/ProtSSN-master/zeroshot_predict.py", line 81, in predict
mutant_df[args.score_name] = mutant_df[args.mutant_pos_col].apply(
File "/home/miniconda/envs/gpu9/lib/python3.9/site-packages/pandas/core/series.py", line 4757, in apply
return SeriesApply(
File "/home/miniconda/envs/gpu9/lib/python3.9/site-packages/pandas/core/apply.py", line 1209, in apply
return self.apply_standard()
File "/home/miniconda/envs/gpu9/lib/python3.9/site-packages/pandas/core/apply.py", line 1289, in apply_standard
mapped = obj._map_values(
File "/home/miniconda/envs/gpu9/lib/python3.9/site-packages/pandas/core/base.py", line 921, in _map_values
return algorithms.map_array(arr, mapper, na_action=na_action, convert=convert)
File "/home/miniconda/envs/gpu9/lib/python3.9/site-packages/pandas/core/algorithms.py", line 1814, in map_array
return lib.map_infer(values, mapper, convert=convert)
File "lib.pyx", line 2926, in pandas._libs.lib.map_infer
File "/home/structure/ProtSSN-master/zeroshot_predict.py", line 82, in
lambda x: label_row(x, seq, out.cpu().numpy(), offset)
File "/home/structure/ProtSSN-master/zeroshot_predict.py", line 45, in label_row
assert sequence[idx] == wt, f"The {row}, {sequence[idx]}"
AssertionError: The A5V, V

Problem when using run_pt.py

I met a problem when i testing the pre-train part of your code. I use: bash script/run_pt.sh. to follow your Start Training part in README, and find that the process is blocked at the Epoch 1 /100. Eventually the process will be forcibly killed. I also tried to interrupt the process and found that it stuck at reading the length of dataloader. I wonder if this is due to hardware requirements that don't support pre-training(using RTX 3090), and looking forward to your reply very much.

The output is as follow:
image

image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.