Skip to main content

Overview

Benchmarking helps you evaluate model performance on:
  • Molecular optimization tasks
  • Property prediction accuracy
  • Generation diversity and validity
  • Oracle efficiency
This guide covers metrics, evaluation workflows, and result analysis.

Optimization Metrics

Top-K Scores

Track the average scores of top-performing molecules:
Metrics tracked:
  • Top-1: Best scoring molecule
  • Top-10: Average of 10 best molecules
  • Top-100: Average of 100 best molecules
  • AUC: Area under the curve for top-N scores over time

Logging During Optimization

The oracle’s log_intermediate() method tracks progress:
Example output:

Diversity Metrics

Internal Diversity

Measure molecular diversity using Tanimoto similarity:
Higher diversity scores (closer to 1.0) indicate more structurally diverse molecules.

Tanimoto Similarity

Compare generated molecules to a reference set:

Running Multiple Trials

Perform multiple optimization runs with different seeds:

Benchmark Configuration

Standard Benchmark Setup

Analyzing Results

Result Files

Each optimization run generates a log file:
results.log

Parsing Results

Visualization

Comparing Models

Best Practices

  • Use fixed seeds for reproducible results
  • Save configuration files with results
  • Record model checkpoints and versions
  • Document data preprocessing steps
  • Run at least 5-10 trials per condition
  • Report mean and standard deviation
  • Use statistical tests (t-test, Mann-Whitney) for comparisons
  • Account for random seed variation
  • Monitor GPU memory usage during long runs
  • Use checkpointing for multi-day experiments
  • Clear cache between runs: torch.cuda.empty_cache()
  • Save intermediate results periodically
  • Verify SMILES validity with RDKit
  • Check for duplicate molecules
  • Validate oracle scores manually on samples
  • Inspect top molecules for chemical sense
When comparing models, ensure they use the same oracle implementation, configuration, and random seeds for fair comparison.

Next Steps

Custom Oracles

Create custom scoring functions for your tasks

Tokenization

Understand tokenizer configuration and special tokens