Skip to content

Release v0.3.21

Latest

Choose a tag to compare

@DarnellGranberry DarnellGranberry released this 13 Nov 19:38
021faba

v0.3.21

This release fixes several bugs that affected training results in 0.3.x and adds a proper test suite so they don't come back. We recommend everyone on 0.3.x update.

Training fixes

  • Fixed the particle pixel count in 2D, which made the estimated particle fraction (pi) about 7x too high.
  • Fixed negative sampling, which could draw "negative" crops on top of labeled particles.
  • Fixed data loader workers producing identical batches, as found #260 by @i7878 and @bsobol.
  • topaz train now accepts TIFF and PNG micrographs, not just MRC.

Extraction and segmentation

  • Fixed the 3D radius search in topaz extract (--targets with --dims 3).
  • --patch-size now works the same way in extract and segment: it is the size of the region scored per patch, and padding of half the model's receptive field is added automatically. Larger patches are faster but use more memory.
  • Fixed segment --patch-size crashing, and extract crashing when --output is an existing directory.

Image and file handling

  • MRC headers written by preprocess and downsample now have the correct size, pixel size and statistics.
  • PNG and JPEG images load with their original values instead of raw 0-255.
  • Fixed convert --invert-y, reading VIA .csv files with pandas 2, and coordinate writers dropping z_coord.
  • Fixed average precision for float64 inputs.

Testing and packaging

  • New pytest suite (341 tests) run on Python 3.8 to 3.13 before every release. See test/walkthrough.ipynb for what each test checks.
  • Pretrained denoising models no longer need pkg_resources.
  • Python 3.13 patch releases (3.13.x) can now install topaz.

Thanks to everyone who reported issues!