Metadata-Version: 2.4
Name: debye3d
Version: 0.1.3
Summary: 3D X-ray and electron scattering calculator using Debye equation
Author-email: Nicolas Ratel-Ramond <nicolas.ratel-ramond@insa-toulouse.fr>
Maintainer-email: Nicolas Ratel-Ramond <nicolas.ratel-ramond@insa-toulouse.fr>
License: MIT
Project-URL: Homepage, https://github.com/nicoratel/debye3d
Project-URL: Documentation, https://github.com/nicoratel/debye3d
Project-URL: Repository, https://github.com/nicoratel/debye3d
Project-URL: Bug Tracker, https://github.com/nicoratel/debye3d/issues
Keywords: scattering,debye,x-ray,crystallography,saxs
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Science/Research
Classifier: Topic :: Scientific/Engineering :: Physics
Classifier: Topic :: Scientific/Engineering :: Chemistry
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy>=1.20.0
Requires-Dist: scipy>=1.7.0
Requires-Dist: matplotlib>=3.3.0
Requires-Dist: ase>=3.22.0
Requires-Dist: pyyaml>=5.4.0
Requires-Dist: tqdm>=4.60.0
Requires-Dist: pyFAI>=0.20.0
Requires-Dist: numba>=0.54.0
Provides-Extra: gpu
Requires-Dist: torch>=1.9.0; extra == "gpu"
Provides-Extra: full
Requires-Dist: torch>=1.9.0; extra == "full"
Requires-Dist: debyecalculator>=1.0.0; extra == "full"
Provides-Extra: dev
Requires-Dist: pytest>=7.0.0; extra == "dev"
Requires-Dist: pytest-cov>=3.0.0; extra == "dev"
Requires-Dist: black>=22.0.0; extra == "dev"
Requires-Dist: flake8>=4.0.0; extra == "dev"
Requires-Dist: mypy>=0.950; extra == "dev"
Dynamic: license-file

# Debye3D

3D scattering calculator using the Debye equation for X-ray and electron scattering.

## Description

`debye3d` is a Python package for computing 2D projections of 3D scattering patterns from atomic structures using the Debye scattering equation. It supports GPU (PyTorch) and CPU (Numba) acceleration for high-performance calculations.

## Installation

### Installation from PyPI

```bash
pip install debye3d
```

### Installation with GPU acceleration

```bash
pip install debye3d[gpu]
```

### Installation with all features

```bash
pip install debye3d[full]
```

### Installation from source (development)

```bash
git clone https://github.com/nicoratel/Debye3D.git
cd Debye3D
pip install -e .
```

## Dependencies

### Required
- numpy >= 1.20.0
- scipy >= 1.7.0
- matplotlib >= 3.3.0
- ase >= 3.22.0
- pyyaml >= 5.4.0
- tqdm >= 4.60.0

### Optional
- **GPU**: torch >= 1.9.0
- **CPU acceleration**: numba >= 0.54.0
- **Detectors**: pyFAI >= 0.20.0
- **DebyeCalculator**: debyecalculator >= 1.0.0

## Usage

Refer to Jupyter notebooks for application examples

## Key Features

- 🔬 3D scattering calculation using Debye equation
- ⚡ GPU support (PyTorch) and CPU acceleration (Numba)
- 🎯 Atomic form factors (Cromer-Mann and Lobato parametrizations)
- 🌐 Orientation averaging with adaptive Fibonacci grid
- 📊 Integration with pyFAI for detector simulations
- 💾 Utilities for saving and visualizing data

## Package Structure

```
debye3d/
├── debye3d.py                          # Main Debye calculation functions
├── compute_f0.py                       # Atomic form factors
├── lobato_scattering.py                # Lobato parametrizations
├── adaptative_fibonacci.py             # Adaptive Fibonacci grid
├── generate_paracrystal_assembly.py    # Supercell generation
├── utilities.py                        # Utilities (I/O, visualization)
└── elements_info.yaml                  # Element database
```

