Skip to main content

Erase masked regions from cryo-EM images

Project description

torch-cryoeraser

License PyPI Python Version CI codecov

torch-cryoeraser is a Python package for erasing local regions of cryo-EM images.

result of using torch-cryoeraser

Image data in masked regions are replaced with noise matching local image statistics.

Installation

pip install torch-cryoeraser

Usage

import torch
import tifffile
from torch_cryoeraser import erase_region_2d

# load image and mask
image = tifffile.imread("image.tif")
mask = tifffile.imread("mask.tif")

# to torch tensor
image = torch.tensor(image)
mask = torch.tensor(mask)

# erase masked regions
erased_image = erase_region_2d(image=image, mask=mask)

for more info, please check the documentation.

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

torch_cryoeraser-0.5.0.tar.gz (127.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

torch_cryoeraser-0.5.0-py3-none-any.whl (6.8 kB view details)

Uploaded Python 3

File details

Details for the file torch_cryoeraser-0.5.0.tar.gz.

File metadata

  • Download URL: torch_cryoeraser-0.5.0.tar.gz
  • Upload date:
  • Size: 127.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for torch_cryoeraser-0.5.0.tar.gz
Algorithm Hash digest
SHA256 29b32a5eb85fcd6020550cf8e6d4bb0b8a40d43fd4907deab561e5b8df4cfcc1
MD5 92aacbeba4da721604ba0741fc7feb32
BLAKE2b-256 cf3b51b63c8513b4dea653a4c925ac02e3b80f1e2c3f40a4eb12fad5819ba1b3

See more details on using hashes here.

Provenance

The following attestation bundles were made for torch_cryoeraser-0.5.0.tar.gz:

Publisher: deploy.yml on teamtomo/teamtomo

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file torch_cryoeraser-0.5.0-py3-none-any.whl.

File metadata

File hashes

Hashes for torch_cryoeraser-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2c9365c465aa1e0ebf742378ca62977c611a770afada9786d71807d3a36540f4
MD5 b5c82f31b2f2d29be22f67bc5ad076f3
BLAKE2b-256 093a37c4e617ffb39a60363e748730eb04d4b2f5945e3870684463d6706d981c

See more details on using hashes here.

Provenance

The following attestation bundles were made for torch_cryoeraser-0.5.0-py3-none-any.whl:

Publisher: deploy.yml on teamtomo/teamtomo

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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