A Python toolkit for protein-ligand interaction analysis using hybrid point cloud and graph neural network (GNN) representations.
- Combined GNN and point cloud representations for comprehensive molecular analysis
- Explicit modeling of chemical bonding information (hydrogen bonds, covalent bonds, aromatic rings)
- Integration of topological and 3D spatial information
- Enhanced capture of chemical bond-dependent interactions
- Graph Neural Networks (GNN) for molecular topology
- Point cloud processing for 3D spatial features
- PointTransformer for feature integration
- Two-stage processing pipeline
- Protein backbone and key side chain atom graph construction
- Ligand molecular graph processing
- GNN-based feature extraction (GraphConv/GAT)
- Topological feature embedding
- 3D coordinate integration with graph features
- PointTransformer processing
- Binding affinity prediction
- End-to-end training
- Python 3.7
- PyTorch with CUDA support
- RDKit (molecular graph processing)
- OpenBabel (hydrogen addition)
- BioPython/PyG/DGL (protein graph construction)
- PDB format files (proteins and ligands)
- Create and activate conda environment:
conda create -n point_cloud_envs python=3.7
conda activate point_cloud_envs
- Install core dependencies:
# PyTorch and CUDA
conda install pytorch torchvision torchaudio cudatoolkit=11.1 -c pytorch -c conda-forge
# Molecular processing tools
conda install -c conda-forge rdkit
conda install -c conda-forge openbabel
conda install -c conda-forge biopython
# Graph neural network libraries
pip install torch-geometric
pip install dgl-cuda11.1
# Other requirements
pip install -r requirements.txt
point-cloud-plus/
├── models/
│ ├── gnn_encoder.py # Graph neural network modules
│ ├── point_transformer.py # Point cloud processing
│ └── fusion.py # Feature fusion modules
├── data_processing/
│ ├── graph_builder.py # Molecular graph construction
│ ├── point_cloud_gen.py # Point cloud generation
│ └── data_prep.py # Data preparation utilities
├── training/
│ ├── trainer.py # Training loop implementation
│ └── loss.py # Loss functions
└── utils/
├── molecule_utils.py # Molecular processing utilities
└── visualization.py # Visualization tools
Process molecular structures:
# Add hydrogens and clean structures
python data_processing/data_prep.py --input protein.pdb --output protein_processed.pdb
# Generate molecular graphs and point clouds
python data_processing/graph_builder.py --input protein_processed.pdb --output graphs/
python data_processing/point_cloud_gen.py --input protein_processed.pdb --output pointclouds/
python training/trainer.py \
--train_data path/to/train \
--valid_data path/to/valid \
--model hybrid \
--epochs 100
python predict.py \
--protein protein.pdb \
--ligand ligand.pdb \
--model_weights path/to/weights
class MoleculeGraphEncoder(nn.Module):
def __init__(self, in_dim, out_dim):
super(MoleculeGraphEncoder, self).__init__()
self.gnn1 = GATConv(in_dim, out_dim // 2)
self.gnn2 = GATConv(out_dim // 2, out_dim)
def forward(self, graph, node_feats):
h = self.gnn1(graph, node_feats)
h = F.relu(h)
h = self.gnn2(graph, h)
return h
# Combine GNN features with 3D coordinates
fused_feats = torch.cat([gnn_feats, xyz_feats], dim=-1)
output = point_transformer(xyz, fused_feats)
- Improved R-value compared to pure point cloud methods
- Better capture of chemical bond-dependent interactions
- Enhanced prediction accuracy for complex protein-ligand interactions
If you use this software in your research, please cite:
# Add citation information here
Contributions are welcome! Please read our contributing guidelines before submitting pull requests.
This project is licensed under the MIT License - see the LICENSE file for details.
For questions and support, please open an issue on GitHub.