| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
ProtSCAPE-Net - Learning Protein Conformational Landscapes from Molecular Dynamics for Ensemble and Transition Path Generation
ProtSCAPE-Net combines multiple state-of-the-art techniques to learn and generate protein conformational landscapes:
✨ Structure Reconstruction: Atomic-level protein structure prediction from graph representations
🧬 Conformational Ensemble Generation: Sample diverse protein conformations via latent diffusion
🛤️ Transition Path Discovery: Generate minimum energy paths between conformational states
📊 MolProbity Integration: Automated structure quality assessment
⚡ Efficient Training: PyTorch Lightning with mixed precision and distributed training support
# Clone the repository
git clone https://github.com/yourusername/ProtSCAPE-Net.git
cd ProtSCAPE-Net
# Install uv (Linux/macOS)
curl -LsSf https://astral.sh/uv/install.sh | sh
# Create and activate a virtual environment
uv venv
source .venv/bin/activate
# Install dependencies
uv sync
# On clusters with CUDA 12.8 drivers, replace the default CUDA 13.0 wheel.
uv pip install --python .venv/bin/python --index-url https://download.pytorch.org/whl/cu128 torch==2.10.0If torch.cuda.is_available() warns that the NVIDIA driver is too old, the environment usually has a newer CUDA wheel than the node driver supports. This repo has been tested on cluster nodes with CUDA 12.8 drivers, so install the matching cu128 PyTorch build before training on GPU.
For advanced visualization:
uv pip install "phate>=0.2.5"For MolProbity metrics:
# Requires phenix.molprobity (install separately)
# See: https://www.phenix-online.org/# Use a pre-configured setup
python train.py --config configs/config.yaml
# Or specify a protein
python train.py --config configs/config.yaml --protein 7lp1# Evaluate on test data
python inference.py --config configs/config_inference.yaml --ckpt_path checkpoints/best_model.pt# Run the complete pipeline: AE training → DDPM training → generation
python ensemble_gen.py --config configs/config_ensemble.pyProtSCAPE-Net/ ├── protscape/ # Core model implementations │ ├── protscape.py # Main ProtSCAPE model │ ├── autoencoder.py # Variational autoencoder │ ├── transformer.py # Transformer encoder │ ├── bottleneck.py # Latent space bottleneck │ ├── generate.py # Path generation algorithms │ ├── neb.py # Nudged Elastic Band │ └── wavelets.py # Scattering transform layer ├── utils/ # Utility functions │ ├── generation_helpers.py │ ├── generation_viz.py │ ├── geometry.py # Kabsch alignment, RMSD │ └── config.py # Configuration loading ├── configs/ # Configuration files │ ├── config.yaml # Training config │ ├── config_inference.yaml │ ├── config_ensemble.py │ └── CONFIG_GUIDE.md # Configuration documentation ├── data/ # Data preparation scripts │ ├── prepare_atlas.py │ ├── prepare_deshaw.py │ └── download_*.py ├── docs/ # Documentation │ └── PATH_GENERATION_METHODS.md ├── train.py # Training script ├── inference.py # Inference/evaluation script ├── ensemble_gen.py # Ensemble generation pipeline └── requirements.txt # Python dependencies
Train ProtSCAPE on protein conformational data:
python train.py --config configs/config.yamlKey training parameters (in config.yaml):
Training outputs:
Evaluate a trained model:
python inference.py --config configs/config_inference.yaml --ckpt_path checkpoints/best_model.ptOutputs:
Key metrics:
Generate conformational ensembles using latent diffusion:
python ensemble_gen.py --config configs/config_ensemble.pyPipeline stages:
Generate transition paths between conformational states:
# LEP method (Langevin dynamics)
python ensemble_gen.py --config configs/config_generation.yaml --method LEP
# NEB method (Nudged Elastic Band)
python ensemble_gen.py --config configs/config_generation_neb.yaml --method NEBSee docs/PATH_GENERATION_METHODS.md for detailed comparison of methods.
All parameters are managed via YAML configuration files. See configs/CONFIG_GUIDE.md for detailed documentation.
Example config.yaml:
# Dataset
dataset: "atlas"
protein: "7lp1"
pkl_path: "data/graphs/7lp1_graphs.pkl"
# Model architecture
latent_dim: 128
hidden_dim: 256
embedding_dim: 128
n_layers: 4
n_heads: 8
# Training
n_epochs: 1000
batch_size: 32
lr: 0.0001
weight_decay: 0.0001
# Normalization
normalize_xyz: true
normalize_energy: true
# Logging
wandb_project: "protscape"
save_dir: "checkpoints/"Command-line overrides:
python train.py --config config.yaml --batch_size 64 --lr 0.0005# Download and prepare ATLAS dataset
cd data/
python download_atlas.py
python prepare_atlas.py --protein 7lp1
# Prepare DE Shaw data
python download_deshaw.py
python prepare_deshaw.py --protein ubiquitinData format: Preprocessed graphs stored as .pkl files with:
Stochastic trajectory generation using Langevin dynamics with momentum in latent space.
Pros: Explores multiple pathways, handles conformational heterogeneity
Cons: Stochastic, may not find true minimum energy path
method: "LEP"
steps: 1000
step_size: 1e-10
momentum: 0.9Deterministic optimization to find minimum energy pathways.
Pros: Finds true MEP, identifies transition states
Cons: Deterministic, computationally intensive
method: "NEB"
n_pivots: 20
neb_steps: 50
neb_lr: 0.05ProtSCAPE combines several key components:
Loss Functions:
Contributions are welcome! Please feel free to submit a Pull Request.
| Back | FazBrowse Home | New Git URL |