본문으로 건너뛰기
cccskills
무료GitHub에 공개

molecule-visualization

Publication-quality molecular visualization. 2D structure drawings (PNG/SVG), molecule grids with property annotations, scaffold highlighting, protein-ligand interaction diagrams, and interactive 3D views.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(7)

  • SKILL.md6.3 KB
  • references/style_guide.md6.8 KB
  • scripts/draw_2d.py8.2 KB
  • scripts/draw_grid.py11.9 KB
  • scripts/draw_interactions.py17.0 KB
  • scripts/draw_scaffold.py15.4 KB
  • scripts/render_3d.py22.9 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Molecule Visualization

Generate publication-quality molecular images for drug discovery, medicinal chemistry, and computational chemistry workflows. This skill provides a comprehensive suite of tools for rendering 2D structural drawings, annotated molecule grids, scaffold decomposition views, protein-ligand interaction diagrams, and interactive 3D molecular viewers.

When to Use

  • 2D structure drawings: Generate clean, high-resolution depictions of small molecules for papers, patents, reports, and presentations.
  • Molecule grids: Compare compound series side-by-side with property annotations (QED, LogP, MW, etc.).
  • Scaffold highlighting: Visualize SAR by decomposing molecules into core scaffolds and R-groups.
  • Interaction diagrams: Summarize protein-ligand binding modes from docking or crystal structures.
  • 3D interactive views: Create browser-based 3D viewers for proteins, ligands, and complexes.

Installation

All scripts require Python 3.8+ and the following packages:

# Core (required for all scripts)
pip install rdkit-pypi pillow matplotlib

# For protein-ligand interaction diagrams
pip install biopython

# For 3D interactive views
pip install py3Dmol

# Full installation
pip install rdkit-pypi pillow matplotlib biopython py3Dmol

Core Workflows

1. Single Molecule Drawing (scripts/draw_2d.py)

Render a single molecule as a high-quality PNG or SVG image.

# Basic usage
python scripts/draw_2d.py --smiles "c1ccccc1" --output benzene.png

# With atom highlighting and title
python scripts/draw_2d.py \
  --smiles "CC(=O)Oc1ccccc1C(=O)O" \
  --output aspirin.svg \
  --title "Aspirin" \
  --highlight-atoms 0,1,2,3 \
  --highlight-color "#4A90D9"

# Show atom indices for reference
python scripts/draw_2d.py \
  --smiles "c1ccc(NC(=O)c2ccccc2)cc1" \
  --output benzanilide.png \
  --show-atom-indices \
  --size 600x400

2. Molecule Grid (scripts/draw_grid.py)

Compare multiple molecules in a grid layout with optional property annotations.

# From CSV file
python scripts/draw_grid.py \
  --input compounds.csv \
  --output grid.png \
  --cols 4 \
  --properties "qed,mw,logp"

# From comma-separated SMILES
python scripts/draw_grid.py \
  --input "c1ccccc1,c1ccncc1,c1ccoc1" \
  --output ring_comparison.png \
  --title "Aromatic Ring Comparison"

3. Scaffold Highlighting (scripts/draw_scaffold.py)

Decompose molecules into scaffolds and R-groups for SAR analysis.

# Manual scaffold specification
python scripts/draw_scaffold.py \
  --smiles "c1ccc(NC(=O)c2ccccc2Cl)cc1" \
  --scaffold "c1ccc(NC(=O)c2ccccc2)cc1" \
  --output scaffold.png

# Automatic Murcko scaffold detection
python scripts/draw_scaffold.py \
  --smiles "CC(=O)Oc1ccccc1C(=O)O" \
  --scaffold auto \
  --output murcko.png

# R-group decomposition across analogs
python scripts/draw_scaffold.py \
  --smiles "c1ccc(NC(=O)c2ccccc2)cc1" \
  --scaffold "c1ccc(NC(=O)c2ccccc2)cc1" \
  --analogs analogs.csv \
  --output rgroup_table.png

4. Protein-Ligand Interaction Diagram (scripts/draw_interactions.py)

Generate 2D interaction diagrams from protein-ligand complexes.

python scripts/draw_interactions.py \
  --protein receptor.pdb \
  --ligand ligand.sdf \
  --output interactions.png \
  --distance-cutoff 4.0

5. Interactive 3D View (scripts/render_3d.py)

Create self-contained HTML files with interactive 3D molecular viewers.

# Protein with cartoon representation
python scripts/render_3d.py \
  --input protein.pdb \
  --output view.html \
  --style cartoon \
  --color chain

# Protein-ligand complex
python scripts/render_3d.py \
  --input protein.pdb \
  --ligand ligand.sdf \
  --output complex.html \
  --style cartoon

6. Pocket Visualization (scripts/render_3d.py --mode pockets)

Visualize detected binding pockets as colored spheres on the protein surface. Sphere color indicates druggability: green (>0.7), orange (0.4-0.7), red (<0.4). Sphere size is proportional to pocket volume.

# After pocket-detection/detect.py or druggability.py
python scripts/render_3d.py \
  --input protein.pdb \
  --pockets druggability.json \
  --mode pockets \
  --output pocket_view.html

# With specific residues highlighted
python scripts/render_3d.py \
  --input protein.pdb \
  --pockets pockets.json \
  --mode pockets \
  --highlight-residues "189,195,57" \
  --output pocket_view.html

7. Docking Results Visualization (scripts/render_3d.py --mode docking-results)

Overlay top docked poses on the protein, colored by rank (green = best, red = worst). The top-ranked pose gets a translucent surface highlight.

# After molecular-docking/dock.py
python scripts/render_3d.py \
  --input protein.pdb \
  --poses dock_results/poses.sdf \
  --mode docking-results \
  --top-n 5 \
  --output docking_results.html

Script Reference

ScriptPurposeKey Inputs
draw_2d.pySingle molecule 2D drawingSMILES, output path
draw_grid.pyMulti-molecule gridCSV or SMILES list, output path
draw_scaffold.pyScaffold and R-group analysisSMILES, scaffold, output path
draw_interactions.pyProtein-ligand interactionsPDB, SDF, output path
render_3d.pyInteractive 3D viewerPDB/SDF/SMILES, output HTML

Style Guide

See references/style_guide.md for detailed guidance on:

  • Colors: CPK atom coloring scheme (C=gray, N=blue, O=red, S=yellow, Cl=green, etc.)
  • Resolution: 300 DPI minimum for print; 150 DPI for screen. Vector (SVG) preferred for publications.
  • Font sizes: 12pt minimum for labels in figures; 8pt minimum for atom indices.
  • Image dimensions: Single molecule 400x300px default; grid cells 300x250px; interaction diagrams 800x800px.
  • Interaction colors: Green for H-bonds, gray for hydrophobic, orange for pi-stacking, red for salt bridges.
  • Colorblind-friendly: Prefer blue/orange instead of red/green when accessibility is a concern.
  • 2D vs 3D: Use 2D for SAR tables, patent figures, and print publications. Use 3D for binding mode analysis, presentations, and supplementary material.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Simplest distributed training API. 4 lines to add distributed support to any PyTorch script. Unified API for DeepSpeed/FSDP/Megatron/DDP. Automatic device placement, mixed precision (FP16/BF16/FP8). Interactive config, single launch command. HuggingFace ecosystem standard.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

huang-sh/DeepScience42026년 7월 15일 업데이트

ADMET property prediction for drug candidates. Full pharmacokinetic panel (Caco-2, PPB, clearance, CYP), toxicity (hERG, AMES, DILI), drug-likeness (Lipinski, QED), using RDKit descriptors and TDC models.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

huang-sh/DeepScience42026년 7월 15일 업데이트

Interpretable ADMET analysis with mechanistic reasoning. Maps liabilities to structural causes and biological pathways. Based on CoTox (Park 2025) and DrugR (Liu 2026).

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

huang-sh/DeepScience42026년 7월 15일 업데이트

aeon

무료

This skill should be used for time series machine learning tasks including classification, regression, clustering, forecasting, anomaly detection, segmentation, and similarity search. Use when working with temporal data, sequential patterns, or time-indexed observations requiring specialized algorithms beyond standard ML approaches. Particularly suited for univariate and multivariate time series analysis with scikit-learn compatible APIs.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

huang-sh/DeepScience42026년 7월 15일 업데이트

arboreto

무료

Infer gene regulatory networks (GRNs) from gene expression data using scalable algorithms (GRNBoost2, GENIE3). Use when analyzing transcriptomics data (bulk RNA-seq, single-cell RNA-seq) to identify transcription factor-target gene relationships and regulatory interactions. Supports distributed computation for large-scale datasets.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

huang-sh/DeepScience42026년 7월 15일 업데이트

astropy

무료

Comprehensive Python library for astronomy and astrophysics. This skill should be used when working with astronomical data including celestial coordinates, physical units, FITS files, cosmological calculations, time systems, tables, world coordinate systems (WCS), and astronomical data analysis. Use when tasks involve coordinate transformations, unit conversions, FITS file manipulation, cosmological distance calculations, time scale conversions, or astronomical data processing.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

huang-sh/DeepScience42026년 7월 15일 업데이트

huang-sh의 스킬 모두 보기

이 스킬의 문제 신고