Skip to main content

Overengineered batch processing script for tomography data with Warp and aretomo.

Project description

waretomo

License PyPI Python Version CI codecov

Overengineered batch processing script for tomography data with Warp and aretomo.

Installation and usage

pip install waretomo
waretomo -h

Walkthrough

Here's a short summary of how I recommend using this script:

  • pre-process your dataset in Warp, up to Create stack for imod. Make sure to deselect bad tilts from the warp interface; they will be skipped in subsequent steps
  • run waretomo in dry-run mode (-d), to make sure everything is set up correctly. Pass any other options you'd like (see waretomo -h for a complete list and shorthands):
waretomo . --mdoc-dir ./mdocs  -b 8 -t 800 -d
  • follow error messages if any arise (you may have to provide the path to the AreTomo executable with --aretomo, for example)
  • once the above command works, it will give you a summary of inputs and of the upcoming pipeline. It's time to try to run it on a single tomogram, using -j (--just). Note that the name to provide to -j is the tomogram name given at the top of the mdoc file (ImageFile = <something>), and not the input file (this is because warp actually uses this value for all subsequent outputs).
waretomo . --mdoc-dir ./mdocs  -b 8 -t 800 -j tiltseries_23.mrc
  • this will run the full pipeline on that tomogram. Keep an eye out for error messages, they might give you tips for solving them.
  • if everything works, you will now have a few outputs to check out:
    • ./waretomo_processing/tiltseries_23.mrc: raw aretomo reconstruction.
    • ./waretomo_processing/denoised/tiltseries_23.mrc: same as above, denoised with topaz for better annotation
    • <mdoc-dir>/mdoc_tilted/tiltseries_23.mrc.mdoc: mdoc file updated with skipped tilt and with adjusted tilt angles from aretomo's TiltAlign option (e.g: to align lamellae to the XY plane)
    • ./waretomo_processing/tiltseries_23.xf: alignment metadata, used by warp together with above mdocs for reconstruction.
  • check out the reconstructions and make sure everything looks as you want. If anything is wrong, adjust parameters as you see fit. You can also run only parts of the script by using the --start-from and --stop-at options (both are inclusive). Use -f if you want to overwrite existing outputs.
  • once you're happy, remove the -j option to process the full dataset.

At this point, you're ready to go back to Warp. Here, you can simply import tilt series from IMOD. Don't forget to provide the mdoc_tilted directory instead of the original mdocs. Set waretomo_processing as the Root folder with IMOD processing results, and Warp will find the xf files located there. Provide the pixel size of the binned aretomo reconstructions (find out with e.g: header waretomo_processing/tiltseries_23.mrc.mrc). You might have to provide the dose per tilt, depending on the origin/correctness of your mdocs.

You can now proceed with reconstructing with Warp, use M, and so on, while having matching AreTomo reconstructions with their local patch alignments and subsequent denoising to maximize readability for picking and annotation.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

waretomo-0.1.0.tar.gz (27.4 kB view details)

Uploaded Source

Built Distribution

waretomo-0.1.0-py3-none-any.whl (27.2 kB view details)

Uploaded Python 3

File details

Details for the file waretomo-0.1.0.tar.gz.

File metadata

  • Download URL: waretomo-0.1.0.tar.gz
  • Upload date:
  • Size: 27.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for waretomo-0.1.0.tar.gz
Algorithm Hash digest
SHA256 2b383ac56312aca3d0cc6a0a8f369309542cdf105e614b473048a6223ca9415a
MD5 1fd6a30a6ab84c57002b16d193ae5444
BLAKE2b-256 1c888bd4d5a17ace68ad069802efdf2c31f43dbb359bdc800edc21397cf7efc0

See more details on using hashes here.

File details

Details for the file waretomo-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: waretomo-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 27.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for waretomo-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 bc7cc8ea45b6c5ea377336342120d45b8cdde1f0c0dee1bd3bfe581cb4ecee6d
MD5 d02385934c2a26f72ab68a17125a871c
BLAKE2b-256 5dbab2d71a8336cde7417eeaf192fd3283141ab3e4036430ea5c6f3fd4fcdbcd

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page