Skip to main content

A command-line tool to add noise to simulated H5 data.

Project description

nanoBragg_noise

This tool allows synthetic diffraction data to be stored on disk as Bragg peaks alone, with individual background files for maximum compression. It is meant to facilitate the sharing of synthetic diffraction data to drive development of novel data reduction algorithms. It adds noise and background to simulated diffraction data, specifically designed for data generated using the datsimx.sim script with the --noNoise option (see mx_simulate.py), which is a thin wrapper to a nanoBragg-style forward model.

Usage Example

To add noise to a noiseless dataset, use the braggaddnoise command with the following options:

braggaddnoise --dirname simulated_scan --run 3 --nj 20

--dirname: The path to the folder containing the simulated data (e.g., simulated_scan).

--run: The run number used in the datsimx simulation (e.g., 3).

--nj: The number of parallel processes to use for faster processing.

The above command will find all HDF5 files matching shots_3_*h5 in the simulated_scan folder, add the background to them that's stored in the file background_3.h5, and add noise to the result, finally overwriting the existing sim_image datasets.

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

nanobragg_noise-1.9.tar.gz (4.6 kB view details)

Uploaded Source

Built Distribution

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

nanobragg_noise-1.9-py3-none-any.whl (5.1 kB view details)

Uploaded Python 3

File details

Details for the file nanobragg_noise-1.9.tar.gz.

File metadata

  • Download URL: nanobragg_noise-1.9.tar.gz
  • Upload date:
  • Size: 4.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.13

File hashes

Hashes for nanobragg_noise-1.9.tar.gz
Algorithm Hash digest
SHA256 b73fcef407e52b0477dfb9b94fdcd7ea2aa8b8b6cba0dabcd03bd3a38b6783eb
MD5 888cf742259e9274765bdeb3b9b7c4a3
BLAKE2b-256 28e0671795c67d46f5de19e2f7da0d1dae3c99865dfbf2b91fb1ce0c13d1b842

See more details on using hashes here.

File details

Details for the file nanobragg_noise-1.9-py3-none-any.whl.

File metadata

  • Download URL: nanobragg_noise-1.9-py3-none-any.whl
  • Upload date:
  • Size: 5.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.13

File hashes

Hashes for nanobragg_noise-1.9-py3-none-any.whl
Algorithm Hash digest
SHA256 3454733f00af4de775aa017f6d9822ccef36d7507869df36e613481b77699427
MD5 2c53939197c7628674842de346655ac6
BLAKE2b-256 82ca79ef4ed13c4abf9b4066c80dbb787e89d3160676fa8f8a1eace3a7f88dbc

See more details on using hashes here.

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