Skip to main content

An xarray-based toolkit for RHEED image analysis

Project description

xRHEED

📡 An xarray-based toolkit for RHEED image analysis.


CI Documentation Status PyPI version License: MIT Code style: black Linter: ruff Package manager: uv DOI


🔬 What is RHEED?

Reflection High-Energy Electron Diffraction (RHEED) is an experimental technique used to monitor and control the quality of crystal surfaces.
A high-energy electron beam (∼20 keV) strikes the surface at a grazing angle (< 5°), making the method highly surface-sensitive and probing only a few atomic layers.


🎯 Project Goals

xRHEED provides a flexible and extensible Python toolkit for RHEED image analysis:

  • 🖼️ Load and preprocess RHEED images
  • 📈 Generate and analyze intensity profiles
  • ✨ Overlay predicted diffraction spot positions (kinematic theory & Ewald construction)
  • 🔄 Transform RHEED images into kx–ky space
  • 🔍 Search for reconstruction lattice constants and rotations by calculating the matching coefficient between predicted and experimental data

👉 Note: xRHEED is not a GUI application. It is designed as an xarray accessory library, intended for use in interactive environments such as Jupyter notebooks.


Installation

Using PyPI

pip install xrheed

Using pip (editable install for development)

git clone https://github.com/mkopciuszynski/xrheed
cd xrheed
pip install -e .

Using uv (with virtual environment)

  1. Install uv.
  2. Clone the repository:
git clone https://github.com/mkopciuszynski/xrheed
cd xrheed
  1. Create and activate a virtual environment.
  2. Sync dependencies:
uv sync

🚀 Quick Usage

import matplotlib.pyplot as plt
import xrheed
from xrheed.io import load_data

# Load a RHEED image
rheed_image = load_data("rheed_image.raw", plugin="dsnp_arpes_raw")

# Show image with auto-adjusted levels
rheed_image.ri.plot_image(auto_levels=2.0)
plt.show()

# Get intensity profile and plot its origin
profile = rheed_image.ri.get_profile(center=(0, -5), width=40, height=4,
                                     plot_origin=True)

📖 Citation

If you use xRHEED in your research, please cite it:

Kopciuszynski, M. ORCID (2025). xRHEED: An xarray-based toolkit for RHEED image analysis.
GitHub. https://github.com/mkopciuszynski/xrheed
DOI: 10.5281/zenodo.17099752


📚 👉 See the full documentation for tutorials and advanced examples.

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

xrheed-1.1.1.tar.gz (32.9 kB view details)

Uploaded Source

Built Distribution

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

xrheed-1.1.1-py3-none-any.whl (35.6 kB view details)

Uploaded Python 3

File details

Details for the file xrheed-1.1.1.tar.gz.

File metadata

  • Download URL: xrheed-1.1.1.tar.gz
  • Upload date:
  • Size: 32.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for xrheed-1.1.1.tar.gz
Algorithm Hash digest
SHA256 917c2f9e8d5138690b26385399ff0ccf8d7313a40cf1df2ea080dcc390b7374f
MD5 339859c1ab932c3882e7df07f4cb7d60
BLAKE2b-256 77b121803549b6d15e879add475a38c0593c13ff4f1dc906fdc0aec002e3f473

See more details on using hashes here.

File details

Details for the file xrheed-1.1.1-py3-none-any.whl.

File metadata

  • Download URL: xrheed-1.1.1-py3-none-any.whl
  • Upload date:
  • Size: 35.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for xrheed-1.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 b4d33deaf88ca7c16b199c69b82625e4a1c6c4f5d531eb16c9e0adfe6bff7769
MD5 2dd140abbc0bbd43332e59f1ee1cde09
BLAKE2b-256 1a2049249f4c9c3e0ea401b9cf72c837fbdf5867f12a1688dd42b511fe9a5667

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