How yonghanyu/deepsearch works
DeepSearch identifies peptides by matching tandem-MS spectra against a digested peptide database in a shared learned embedding space, with optional sequence rescoring. Its separate training workflow learns that model through contrastive and de novo objectives. The graph preserves the documented search and training stages and major model/data components. Some connections are supported only by the README or SOURCE INDEX; unsampled internals are not inferred as direct calls.
Main entry points: bin/search.py Search command · train_model.py Training command · models.py DeepSearch model · search/search.py Database matching
Components 22
Database search
- Search command
bin/search.py - Search parameters
DeepSearch/search/params.py - Spectra readers
DeepSearch/search/dataset.py - Peptide streams
DeepSearch/search/dataset.py - Embedding computation
DeepSearch/search/compute_embedding.py - Search utilities
DeepSearch/search/search_utils.py - Database matching
DeepSearch/search/search.py - PSM result files
Model and sequence
- DeepSearch model
DeepSearch/model/models.py - Transformer modules
DeepSearch/model/modules.py
Model training
- Training command
bin/train_model.py - Training datasets
DeepSearch/training/dataset.py - Contrastive sampler
DeepSearch/training/sampler.py - Training and evaluation
DeepSearch/training/training.py - Contrastive loss
DeepSearch/training/loss.py - Distributed training
DeepSearch/training/distributed.py - Learning-rate schedule
DeepSearch/training/scheduler.py
Shared utilities
- Peptide tokenizer
DeepSearch/utils/tokenizer.py - Peptide chemistry
DeepSearch/utils/peptide.py - Spectrum processing
DeepSearch/utils/spectrum.py
Other components
- Researcher
- Spectra and FASTA
Connections 32
- Researcher → Search command: runs
README.md - Spectra and FASTA → Search command: provides
README.md - Search command → Search parameters: loads parameters
bin/search.py - Search command → Spectra readers: configures spectra
bin/search.py - Search command → Peptide streams: builds peptide candidates
bin/search.py - Search command → DeepSearch model: loads model
bin/search.py - Embedding computation → Spectra readers: batches spectra
DeepSearch/search/compute_embedding.py - Embedding computation → DeepSearch model: encodes spectra
DeepSearch/search/compute_embedding.py - Search command → Embedding computation: computes embeddings
README.md - Search command → Database matching: runs matching
bin/search.py - Database matching → Embedding computation: uses embeddings
README.md - Database matching → Search utilities: calculates match utilities
DeepSearch/search/search.py - Database matching → DeepSearch model: rescores candidates
DeepSearch/search/search.py - Database matching → PSM result files: writes PSM results
README.md - Database matching → Peptide chemistry: uses peptide calculations
DeepSearch/search/search.py - Peptide streams → Peptide tokenizer: tokenizes peptides
DeepSearch/search/dataset.py - Peptide tokenizer → Peptide chemistry: uses amino-acid vocabulary
DeepSearch/utils/tokenizer.py - DeepSearch model → Transformer modules: composes modules
DeepSearch/model/models.py - DeepSearch model → Peptide tokenizer: encodes peptide sequences
DeepSearch/model/models.py - Researcher → Training command: runs
README.md - Spectra and FASTA → Training command: provides training data
README.md - Training command → DeepSearch model: initializes model
bin/train_model.py - Training command → Training datasets: loads datasets
bin/train_model.py - Training command → Contrastive sampler: configures sampler
bin/train_model.py - Training command → Learning-rate schedule: configures schedule
bin/train_model.py - Training command → Contrastive loss: creates loss
bin/train_model.py - Training command → Training and evaluation: starts training
DeepSearch/training/training.py - Training and evaluation → DeepSearch model: trains and evaluates
DeepSearch/training/training.py - Training and evaluation → Distributed training: uses distributed helpers
DeepSearch/training/training.py - Training and evaluation → Learning-rate schedule: steps schedule
DeepSearch/training/training.py - Training datasets → Spectrum processing: bins spectra
DeepSearch/training/dataset.py - Training datasets → Peptide chemistry: uses peptide calculations
DeepSearch/training/dataset.py