Examples#
This section contains practical examples and Jupyter notebooks demonstrating CDIutils functionality.
Example Notebooks
Jupyter Notebook Examples#
The following Jupyter notebooks provide hands-on examples of CDIutils usage:
Interactive 3D Visualisation#
Download: interactive_features.ipynb
New in v0.2.0! Learn to use the modern interactive 3D visualisation tools:
plot_3d_isosurface- Quick interactive isosurface plotting with multiple quantitiesThreeDViewer- Widget for exploring complex 3D arrays (amplitude + phase)TabPlotData- Interactive browser for CDI reconstruction resultsColormap selection and colorbar control (auto-scale, symmetric, manual limits)
NaN handling for clean visualisations
Theme toggle and rotation animations
BCDI Pipeline Example#
Download: bcdi_pipeline_example.ipynb
Complete end-to-end pipeline This comprehensive example demonstrates a full BCDI analysis workflow:
Setting up and running the
BcdiPipelineclassAutomated data processing and phase retrieval
Post-processing and strain analysis
Interactive 3D visualisation with
plot_3d_isosurface(new in v0.2.0)Advanced plotting and figure generation
This example showcases the complete workflow from raw data to publication-ready visualisations, including the new Plotly-based interactive 3D plots.
BCDI Reconstruction Analysis#
Download: bcdi_reconstruction_analysis.ipynb
This notebook demonstrates comprehensive BCDI reconstruction analysis including:
Loading experimental data
Phase retrieval with PyNX
Post-processing and strain analysis
Visualisation and interpretation
CXI File Exploration#
Download: explore_cxi_file.ipynb
Learn how to:
Navigate CXI file structure
Extract reconstruction results
Analyse metadata and experimental parameters
Export data for further processing
Pole Figure Analysis#
Download: pole_figure.ipynb
This example covers:
Stereographic projection analysis
Crystal orientation mapping
Pole figure generation and interpretation
Advanced crystallographic analysis
Template Notebooks#
Ready-to-use templates are available in the templates directory:
bcdi_pipeline.ipynb - Complete BCDI analysis pipeline
step_by_step_bcdi_analysis.ipynb - Detailed step-by-step reconstruction
detector_calibration.ipynb - Detector calibration procedures
Getting Started#
Download the notebook examples above
Install CDIutils following the Installation guide
Run the notebooks in your Jupyter environment
Adapt the examples to your specific datasets