3D classification

This tutorial shows how to convert raw tilt-series from EMPIAR-10304 (E. coli. ribosomes) into a ~4.9A resolution structure and resolve 8 different conformations.

We first use the command line to download and decompress a tbz file containing: 1) a script to download the raw tilt-series from EMPIAR, 2) corresponding metadata with tilt angles and acquisition order, and 3) an initial model:

# cd to a location in the shared file system and run:

wget https://nextpyp.app/files/data/nextpyp_class_tutorial.tbz
tar xfz nextpyp_class_tutorial.tbz
source download_10304.sh

Note

Depending on the speed of your network connection, downloading the raw data from EMPIAR can take several minutes.

Open your browser and navigate to the url of your nextPYP instance (e.g., https://nextpyp.myorganization.org).

Step 1: Create a new project

Data processing runs are organized into projects. We will create a new project for this tutorial
  • The first time you log into nextPYP, you should see an empty Projects page:

    Create new project
  • Click on Create new project, give the project a name, and select Create. Optionally enable Choose folder location (advanced) to set the Folder where project files are stored (otherwise nextPYP chooses a default location)

  • Double-click the new project on the Projects page to open it, or use → Open

  • The newly created project will be empty. A Jobs/Run panel appears on the right

Tip

To skip manual wiring, open the empty project and use Import Workflow to load the corresponding tomography tutorial workflow shipped with nextPYP.

Step 2: Import raw tilt-series

Import the raw tilt-series downloaded above ( <1 min)
  • Click Import Data, open the Tomography tab, and choose Raw Data. This creates a Tomography (from Raw Data) block

    Import dialog
  • Open the Parameters tab (double-click the block on the project page, or use Actions → Edit). Go to the Sources tab:

    File browser
    • Click Add path and browse to the directory where you downloaded the raw tilt images

    • Type tilt*.mrc in the filter box (lower right) and click on the icon to verify your selection. 12 matches should be displayed

    • Click Choose File Pattern to add the path

    • If your download includes *.mdoc (or similar) metadata, set Location of mdoc files on the path as needed

    • Click on the Grouping tab

    • Enable No movie frames (these are already single-image tilts)

    • Click on the Microscope parameters tab

    • Set Pixel size (A) to 2.1

    • Set Acceleration voltage (kV) to 300

  • Click Run

  • After the run finishes, the View tab is populated and a thumbnail is displayed inside the block on the project page. Later runs update the View tab and block thumbnail the same way

Step 3: Pre-processing

4 min - Movie frame alignment, CTF estimation and tomogram reconstruction
  • Click on Tilt-series (output of the Tomography (from Raw Data) block) and select Pre-processing. The new block appears on the project page

  • Open the Parameters tab:

    • (There is no Frame alignment tab here because import enabled No movie frames.) Set Max resolution (A) to 5.0

    • Click on the Tilt-series alignment tab

    • Uncheck Reshape tilt-images into squares

    • Click on the Tomogram reconstruction tab

    • Set Tomogram thickness (unbinned voxels) to 3072

    • Set Binning factor to 12

    • Check Erase fiducials

    • Click on the Resources tab

  • Click Run. Follow the status of the run on the Jobs tab. On that tab, open cluster logs with the control next to a job (tabs such as Launch, Split, and Merge); logs dock at the bottom — maximize with and restore with

Step 4: Particle picking

Particle detection from tomograms ( 2 min)
  • Click on Tomograms (output of the Pre-processing block) and select Particle picking. The new block appears on the project page

  • Open the Parameters tab. Go to the Particle detection tab:

    • Set Detection method to size-based

    • Set Particle radius (A) to 80

    • Set Threshold for contamination detection to 2.0

    • Set Minimum contamination size (voxels) to 60

    • Set Minimum distance between particles to 2

    • Check Local refinement

    • Set Z-axis detection range (binned slices) to 40

    • Set Particle detection threshold to 2

  • Click Run

  • Open the Particle picking block (View tab) to inspect the coordinates

Note

In this tutorial, we use the size-based method for particle detection. Other methods are available, including manual, geometry-based, and neural network-based picking, and molecular pattern mining.

Step 5: Reference-based refinement

Reference-based particle alignment ( 14 hr)
  • Click on Particles (output of the Particle picking block) and select Reference-based refinement. The new block appears on the project page

  • Open the Parameters tab. Go to the Sample tab:

    • Set Molecular weight (kDa) to 2000

    • Set Particle radius (A) to 150

    • Click on the Particle extraction tab

    • Set Box size (pixels) to 64

    • Set Image binning to 4

    • Uncheck Skip gold fiducials

    • Check Invert CTF handedness

    • Click on the Particle scoring function tab

    • Set First tilt for refinement to 15

    • Set Last tilt for refinement to 25

    • Set Max resolution (A) to 22.0

    • Click on the Reference-based refinement tab

    • Specify the location of the Initial model (*.mrc) by clicking on the icon , navigating to the folder where you downloaded the data for the tutorial, and selecting the file EMPIAR-10304_init_ref.mrc

    • Set Particle rotation Phi range (degrees), Particle rotation Psi range (degrees) and Particle rotation Theta range (degrees) to 180

    • Set Rotation step (degrees) to 6.0

    • Set Particle translation range (A) to 50

    • Click on the Reconstruction tab

    • Check Show advanced options

    • Set Max tilt-angle (degrees) to 50

    • Set Min tilt-angle (degrees) to -50

    • Click on the Resources tab

    • Set Split, Threads to the maximum allowable by your system

  • Click Run

  • One round of refinement and reconstruction will be executed. Open the block’s View tab to see the results

Step 6. Filter particles

Identify duplicates and particles with low alignment scores ( 3 min)
  • Click on Particles (output of the Reference-based refinement block) and select Particle filtering. The new block appears on the project page

  • Open the Parameters tab. Go to the Particle filtering tab:

    • Specify the location of Input parameter file (*.bz2) by clicking on the icon and selecting the file tomo-reference-refinement-*_r01_02.bz2

    • Set Score threshold to 15

    • Set Min distance between particles (unbinned pixels/voxels) to 20

    • Set Lowest tilt-angle (degrees) to -7

    • Set Highest tilt-angle (degrees) to 7

    • Check Generate reconstruction after filtering

    • Check Permanently remove particles

  • Click Run. You can see how many particles were left after filtering by looking at the job logs.

Step 7. Fully constrained refinement

Tilt-geometry parameters and particle poses are refined in this step ( 10 min)
  • Click on Particles (output of the Particle filtering block) and select 3D refinement. The new block appears on the project page

  • Open the Parameters tab. Go to the Particle extraction tab:

    • Set Box size (pixels) to 256

    • Set Image binning to 1

    • Click on the Particle scoring function tab

    • Set Max resolution (A) to 18:14

    • Click on the Refinement tab

    • Select the location of the Initial parameter file (*.bz2) by clicking on the icon and selecting the file tomo-fine-refinement-*_r01_clean.bz2

    • Set Last iteration to 3

    • Check Refine tilt-geometry

    • Check Refine particle alignments

    • Set Particle translation range (A) to 30.0

    • Click on the Reconstruction tab

    • Check Apply dose weighting

    • Check Global weights

  • Click Run to execute three rounds of refinement and reconstruction

  • Open the View tab of the 3D refinement block to inspect the results

Step 8: Create shape mask

Use most recent reconstruction to create a shape mask ( <1 min)
  • Click on Particles (output of 3D refinement block) and select Masking. The new block appears on the project page

  • Open the Parameters tab. Go to the Masking tab:

    • Select the Input map (*.mrc) by clicking on the icon and selecting the file tomo-new-coarse-refinement-*_r01_03.mrc

    • Set Threshold for binarization to 0.4

    • Set Width of cosine edge (pixels) to 8

  • Click Run to run the job

  • On the Masking block, open , choose Show filesystem location (or Copy filesystem location), and copy the path for the next step

  • Open the View tab of the Masking block to inspect the results of masking

Step 9. Region-based local refinement

Constraints of the tilt-geometry are applied over local regions ( 25 min)
  • Click on Particles (output of 3D refinement block) and select 3D refinement. The new block appears on the project page

  • Open the Parameters tab. Go to the Particle scoring function tab:

    • Set First tilt for refinement to 18

    • Set Last tilt for refinement to 22

    • Set Max resolution (A) to 18:14:12:10:8:6:5

    • Set Masking strategy to from file

    • Specify the location of the Shape mask (*.mrc) produced in Step 8 by clicking on the icon , navigating to the location of the Masking block by copying the path we saved above, and selecting the file frealign/maps/mask.mrc

    • Click on the Refinement tab

    • Select the location of the Initial parameter file (*.bz2) by clicking on the icon and selecting the file tomo-new-coarse-refinement-*_r01_03.bz2

    • Set Last iteration to 5

    • Set Number of regions to 8,8,2

  • Click Run to run the job

  • Open the View tab of the 3D refinement block to inspect the results

Step 10: Particle-based CTF refinement

Per-particle CTF refinement using most recent reconstruction ( 2 hr)
  • Click on Particles (output of 3D refinement block) and select 3D refinement. The new block appears on the project page

  • Open the Parameters tab. Go to the Particle scoring function tab:

    • Set First tilt for refinement to 15

    • Set Last tilt for refinement to 25

    • Set Max resolution (A) to 4.5

    • Click on the Refinement tab

    • Select the location of the Initial parameter file (*.bz2) by clicking on the icon and selecting the file tomo-new-coarse-refinement-*_r01_05.bz2

    • Uncheck Refine tilt-geometry

    • Uncheck Refine particle alignments

    • Check Refine CTF per-particle

    • Set Defocus 1 range (A) and Defocus 2 range (A) to 2000.0

  • Click Run

  • Open the View tab of the 3D refinement block to inspect the results

Step 11: Region-based refinement after CTF refinement

Constraints of the tilt-geometry are applied over local regions ( 20 min)
  • Click on Particles (output of 3D refinement block) and select 3D refinement. The new block appears on the project page

  • Open the Parameters tab. Go to the Particle scoring function tab:

    • Set First tilt for refinement to 18

    • Set Last tilt for refinement to 22

    • Set Max resolution (A) to 18:14:12:10:8:6:5:4.5:6:5:4.5

    • Click on the Refinement tab

    • Select the location of the Initial parameter file (*.bz2) by clicking on the icon and selecting the file tomo-new-coarse-refinement-*_r01_02.bz2

    • Set Last iteration to 12

    • Check Refine tilt-geometry

    • Check Refine particle alignments

    • Uncheck Refine CTF per-particle

    • Set Number of regions to 16,16,4

    • Set Optimizer - Max step length to 20.0

    • Click on the Reconstruction tab

    • Set Frame weight fraction to 2

  • Click Run to run the job

  • Open the View tab of the 3D refinement block to inspect the results

Step 12: 3D classification

Constrained classification ( 3 hr)
  • Click on Particles (output of the last 3D refinement block) and select 3D classification. The new block appears on the project page

  • Open the Parameters tab. Go to the Classification tab:

    • Select the location of the Initial parameter file (*.bz2) by clicking on the icon and selecting the file tomo-new-coarse-refinement-*_r01_12.bz2

    • Set Last iteration to 20

    • Set Number of classes to 8

    • Uncheck Refine particle alignments

    • Click on the Reconstruction tab

    • Specify the location of the External weights by clicking on the icon and selecting the file frealign/weights/global_weight.txt from the file location of the previous block

  • Click Run

  • Open the View tab of the 3D classification block to inspect the results

    Tip

    Click on the round blue markers (top right of the page) to inspect different classes or go to the Class view or Classes Movie tabs to show all classes simultaneously

Info

Running times were measured running all tilt-series in parallel on nodes with 124 vCPUs, 720GB RAM, and 3TB of local SSDs