Skip to content

Example

The two test cases of DisVis are in the test-cases directory of the repository, with their input files and reference results.

Two test cases, each with reference results and timings on different hardware.

Test case Fixed chain Scanning chain Restraints
PRE5-PUP2-complex O14250.pdb Q9UT97.pdb 7 cross-links
RNA-polymerase-II/A-E 1wcm_A.pdb 1wcm_E.pdb 8 cross-links (from XLdb)

Running the test cases

From the test-case directory, a coarse run (9.72° rotational sampling, 7416 rotations, 2 Å grid)

disvis O14250.pdb Q9UT97.pdb restraints.dat -a 9.72 -vs 2 -p 8 -d coarse

and a fine run (5.27°, 53256 rotations, 1 Å grid)

disvis O14250.pdb Q9UT97.pdb restraints.dat -a 5.27 -vs 1 -p 8 -d fine

Use -g instead of -p 8 to run on the GPU (see INSTALLATION.md). For RNA polymerase II, use 1wcm_A.pdb 1wcm_E.pdb as input. DisVis writes report.html; view it with python -m http.server -d coarse and http://localhost:8000/report.html.

check_test_cases.py runs both test cases and compares the output files byte for byte with the reference results (the report is not compared), e.g. from the repository root:

python test-cases/check_test_cases.py -p 8      # coarse, on the CPU
python test-cases/check_test_cases.py --fine    # fine
python test-cases/check_test_cases.py --gpu     # compared with the GPU references

The GitHub workflow runs it for the coarse test cases on Linux, macOS and Windows.

Reference results

example-results/ contains, for each test case:

  • cpu/coarse and cpu/fine: CPU runs with -p 8 (macOS, Apple M2 Pro, Python 3.14, NumPy 2).
  • gpu/coarse and gpu/fine: GPU runs with -g (Rocky Linux 9, NVIDIA RTX 6000 Ada, Python 3.14), made with the clFFT library. The GPU FFTs now use VkFFT (pyvkfft), which gives byte-identical output for all four runs on the RTX 6000 Ada, the GTX 1080 Ti and the Apple M2 Pro GPU.
  • PRE5-PUP2 only, cpu/coarse-is-oa: the coarse CPU run with -is selection.res -oa (occupancy grids and interaction analysis); its other output files are identical to cpu/coarse.

The CPU output files (accessible_complexes.out, violations.out, z-score.out and accessible_interaction_space.mrc) are byte-identical across Python 3.11–3.14, NumPy FFT or pyFFTW, and macOS (arm64), Linux (x86_64), Docker and Apptainer. The GPU computes in single precision: the numbers of accessible complexes agree with the CPU results to about 1e-5 (relative), and the z-scores and flagged restraints are the same (restraints 1 and 2 for PRE5-PUP2; 7 and 8 for RNA polymerase II). disvis.log records the run time and the absolute paths of the machine that produced the results.

Each directory also has the report of its results (report.html, with state.mvsj and a copy of the fixed chain), made from these files with disvis.report.generate_report; view it with python -m http.server -d <dir> and http://localhost:8000/report.html.

Example reports

The reports of the CPU reference results (open them in a new tab; the Mol* view loads the files of the run):

Test case Run Report
PRE5-PUP2 coarse (9.72°, 2 Å) report
PRE5-PUP2 coarse, with -is selection.res -oa report
PRE5-PUP2 fine (5.27°, 1 Å) report
RNA polymerase II coarse (9.72°, 2 Å) report
RNA polymerase II fine (5.27°, 1 Å) report