ensembl.vep.config.sections.bench package#
Benchmark options: what every verb shares, then one section per verb.
Submodules#
ensembl.vep.config.sections.bench.bench module#
Options every benchmark verb shares.
- class ensembl.vep.config.sections.bench.bench.BenchConfig(*, repeats=3, warmup=1, no_gate=False, results_file=None, baseline_file=None, regression_threshold=0.05, output_format=None)[source]#
Bases:
ConfigSectionHow every benchmark is measured and reported. Read by every
benchverb.- Variables:
repeats (int) – Timed samples per configuration; the best is reported.
warmup (int) – Untimed passes before the first sample.
no_gate (bool) – Skip the conformance gate, which otherwise refuses to time anything until every strategy agrees with the reference. For re-timing a tree already known to conform.
results_file (Path | None) – Write the measured results here as JSON.
baseline_file (Path | None) – Compare against results previously written here.
regression_threshold (float) – Fractional slowdown against the baseline that counts as a regression.
output_format (str | None) – Table format.
- baseline_file: Path | None#
- no_gate: bool#
- output_format: str | None#
- regression_threshold: float#
- repeats: int#
- results_file: Path | None#
- section_name: ClassVar[str] = 'bench'#
- warmup: int#
ensembl.vep.config.sections.bench.endtoend module#
Options for timing whole runs of the command line against each other.
- class ensembl.vep.config.sections.bench.endtoend.BenchEndToEndConfig(*, strategies=(), caches=('none', 'zonemap', 'zonemap+codon'), processes=(1,), batch_size=256, work_dir=None, clean=True)[source]#
Bases:
ConfigSectionWhich configurations to run end to end, where to run them, and what to leave behind.
- Variables:
strategies (tuple[str, ...]) – Strategies to time, or empty for every registered
consequence.*strategy.consequence.linearis run first, as the reference the speed-up column and the output gate are against.caches (tuple[str, ...]) – Cache sets to cross every strategy with:
none, or a+-joined set ofzonemap,codonandmapper. The default matchesbench matrix, so a label means the same run in both tables.processes (tuple[int, ...]) – Worker process counts to cross every configuration with. An axis only an end-to-end benchmark has: the in-process verbs never fork.
batch_size (int) – Overlaps per batch, passed to each run.
work_dir (Path | None) – Where the corpus, its indexes and the run outputs go. Defaults to
corpus.corpus_dirwhen that is set, and to a temporary directory otherwise.clean (bool) – Remove the files this run created when it finishes. Files that were already there are left alone either way.
- batch_size: int#
- caches: tuple[str, ...]#
- clean: bool#
- processes: tuple[int, ...]#
- section_name: ClassVar[str] = 'bench_endtoend'#
- strategies: tuple[str, ...]#
- work_dir: Path | None#
ensembl.vep.config.sections.bench.matrix module#
Options for timing strategies and cache configurations against each other.
- class ensembl.vep.config.sections.bench.matrix.BenchMatrixConfig(*, strategies=(), caches=('none', 'zonemap', 'zonemap+codon'), batch_size=256)[source]#
Bases:
ConfigSectionWhich strategies, crossed with which cache sets.
- Variables:
strategies (tuple[str, ...]) – Strategies to time, or empty for every registered
consequence.*strategy.consequence.linearis always timed first, as the reference the speed-up column is against.caches (tuple[str, ...]) – Cache sets to cross every strategy with:
none, or a+-joined set ofzonemap,codonandmapper. Each configuration gets fresh caches, so none is timed against another’s warmed ones.batch_size (int) – Chunk size for the batch timing.
- batch_size: int#
- caches: tuple[str, ...]#
- section_name: ClassVar[str] = 'bench_matrix'#
- strategies: tuple[str, ...]#
ensembl.vep.config.sections.bench.oracle module#
Options for comparing against the Perl VariationEffect.pm oracle.
- class ensembl.vep.config.sections.bench.oracle.BenchOracleConfig(*, perl_modules=None, perl_oracle_script=PosixPath('bench/variation_effect.pl'), strategies=(), oracle_number=200)[source]#
Bases:
ConfigSectionWhere the Perl oracle lives, and what to compare against it.
- Variables:
perl_modules (Path | None) – ensembl-variation’s
modulesdirectory. Without it the Python strategies are still compared against each other, and the Perl side is skipped with the reason.perl_oracle_script (Path) – The oracle script.
strategies (tuple[str, ...]) – Strategies to compare, or empty for
consequence.linearand, when built,consequence.columnar-kernels.oracle_number (int) – Workload executions per timed repeat.
- oracle_number: int#
- perl_modules: Path | None#
- perl_oracle_script: Path#
- section_name: ClassVar[str] = 'bench_oracle'#
- strategies: tuple[str, ...]#
ensembl.vep.config.sections.bench.sweep module#
Options for sweeping one numeric annotation setting.
- class ensembl.vep.config.sections.bench.sweep.BenchSweepConfig(*, strategies=(), sweep_knob='batch_size', sweep_values=(32, 64, 128, 256, 512, 1024))[source]#
Bases:
ConfigSectionWhich setting to sweep, over which values, for which strategies.
- Variables:
strategies (tuple[str, ...]) – Strategies to sweep, or empty for the batch strategies available here –
consequence.columnar-staged, andconsequence.columnar-kernelswhen the native extension is built.sweep_knob (str) – The setting to vary.
sweep_values (tuple[int, ...]) – The values to try, in order.
- section_name: ClassVar[str] = 'bench_sweep'#
- strategies: tuple[str, ...]#
- sweep_knob: str#
- sweep_values: tuple[int, ...]#
- ensembl.vep.config.sections.bench.sweep.SWEEPABLE_KNOBS = ('batch_size', 'codon_cache_entries', 'mapper_cache_bytes', 'zone_map_bytes')#
The numeric annotation settings a sweep can vary.