kikuchipy is a library for processing, simulating and indexing of electron backscatter diffraction (EBSD) patterns in Python, built on the tools for multi-dimensional data analysis provided by the HyperSpy library:

All user facing changes to this project are documented in this file. The format is based on Keep a Changelog, and this project tries its best to adhere to Semantic Versioning.

List entries are sorted in descending chronological order. Contributors to each release were listed in alphabetical order by first name until version 0.7.0.

0.9.0 (2023-11-03)#


  • Explicit support for Python 3.11. (#646)

  • Allow Hough indexing of all Laue groups with PyEBSDIndex v0.2 (not just m-3m, i.e. FCC and BCC). (#652)

  • Control of reflector lists in Hough indexing. One reflector list per phase in the phase list can be passed to EBSDDetector.get_indexer() to obtain an EBSDIndexer for use in EBSD.hough_indexing(). (#652)

  • Allow passing keyword arguments to EBSD.hough_indexing_optimize_pc() to control the new particle swarm optimization algorithm in PyEBSDIndex v0.2. (#652)

  • Allow getting one projection center (PC) per pattern when optimizing PCs using the new particle swarm optimization in PyEBSDIndex v0.2 (passing batch=True). (#652)


  • Parameter zone_axes_kwargs in GeometricalKikuchiPatternSimulation.as_collections() does not accept color internally to set the default color to white anymore. It accepts fc (facecolor) instead. This change was necessary to improve handling of other keyword arguments. (#643)

  • Increase minimal versions of diffsims, NumPy, Matplotlib, and PyEBSDIndex to 0.5.1, 1.21.6, 3.5, and 0.2, respectively. (#646, #652)

  • Remove dependency on Panel for documentation, and with that the interactive 3D visualization of master patterns in the documentation. The plan is to reintroduce the interactive plots with trame later on. (#652)

  • Restrict HyperSpy to below the forthcoming version 2. The plan is to remove this restriction once kikuchipy is compatible with this version. (#657)


  • generators and projections modules which were deprecated in version 0.8. (#612)

  • The deprecated PyPI selector viz is removed. (#643)

  • The data module functions silicon_ebsd_moving_screen_x(), where “x” is “in”, “out5mm” or “out10mm”. They were deprecated in version 0.8. (#656)


  • Conversion from EDAX TSL projection center (PC) convention for (PCy, PCz) for rectangular detectors is corrected. (#652)

  • Downloading files in the data module to the local cache on Windows. (#655)

0.8.7 (2023-07-24)#


  • Passing a 3-component PC array with more than one dimension to EBSD.hough_indexing_optimize_pc() works. (#647)

0.8.6 (2023-05-29)#


  • Use memory mapping (numpy.memmap()) instead of reading into memory (numpy.fromfile()) for non-lazy reading of EBSD patterns from EDAX binary .up1/2 files. (#641)


  • EBSD patterns from some EDAX binary .up1/2 files were incorrectly read due to an incorrect file offset, making the patterns appear shifted horizontally. (#641)

  • Reading of EBSD patterns from H5OINA files with the “Camera Binning Mode” dataset not containing the detector binning. (#641)

0.8.5 (2023-05-21)#


  • Not-indexed points in crystal maps are handled correctly when merging. (#639)

0.8.4 (2023-04-07)#


  • Points considered not-indexed in a crystal map are maintained after EBSD refinement. (#632)


  • EBSD detector returned from combined EBSD and projection center (PC) refinement now has PC values equal to the number of indexed points, accounting for points not being in the data, navigation mask and points considered as not-indexed. This means that it might not have a 2D navigation shape, even though the returned crystal map has. (#632)

0.8.3 (2023-03-23)#


  • EBSD.hough_indexing() info message now informs that the given projection center is in Bruker’s convention. (#628)

0.8.2 (2023-03-14)#


  • Set minimal version of orix to >= 0.11.1. (#623)

0.8.1 (2023-02-20)#


  • Hough indexing with PyEBSDIndex of a lazy EBSD signal requires not only PyOpenCL to be installed, but also for PyOpenCL to be able to create a context. (#615)

  • Missing progressbars for EBSD methods average_neighbour_patterns() and fft_filter() reintroduced. (#615)

0.8.0 (2023-02-11)#


  • kikuchipy.imaging.VirtualBSEImager replaces the kikuchipy.generators.VirtualBSEGenerator class. (#608)

  • Adaptive histogram equalization is available to all signals. (#606)

  • Option to return a new signal (lazy or not) instead of operating inplace is added to many methods in all classes via inplace and lazy_output boolean parameters. (#605)

  • Lazy version of the VirtualBSEImage class. (#605)

  • Allow providing a color for simulator reflections when plotting with Matplotlib. (#599)

  • Passing pseudo-symmetry operators to orientation and orientation/PC EBSD refinement methods in order to find the best match among pseudo-symmetric variants. (#598)

  • Saving and loading of an EBSDDetector. (#595)

  • EBSD refinement methods now return the number of function evaluations. (#593)

  • Which points in a crystal map to refine can be controlled by passing a navigation mask. (#593)

  • Which points to consider when merging crystal maps can be controlled by passing navigation masks. (#593)

  • Which patterns to do dictionary indexing of can be controlled by passing a navigation mask. (#593)

  • Downsampling of EBSD patterns which maintain the data type by also rescaling to the data type range. (#592)

  • Method to get a PyEBSDIndex EBSDIndexer instance from an EBSDDetector, convenient for either indexing with PyEBSDIndex or for use with kikuchipy. (#590)

  • Convenience function to get a CrystalMap from a PyEBSDIndex Hough indexing result array. (#590)

  • PyEBSDIndex as an optional dependency. (#590)

  • Two tutorials showing projection center (PC) fitting and extrapolation to obtain a plane of PCs to index a full dataset. (#588)

  • Tutorial showing sloppy projection center (PC)/orientation optimization landscape of the Ni dataset from Jackson et al. (2019), replicating the results from Pang et al. (2020). (#588)

  • Method EBSDDetector.fit_pc() to fit a plane using a projective or affine transformation to projection centers following work by Winkelmann and co-workers (2020). (#587)

  • Method EBSDDetector.extrapolate_pc() to return a new detector with a plane of projection centers (PCs) extrapolated from a mean PC calculated from one or more PCs following work by Singh et al. (2017). (#587)

  • Methods EBSDDetector.estimate_xtilt() and EBSDDetector.estimate_xtilt_ztilt() to estimate the tilts about the detector X and Z axes which bring the detector plane normal parallel to the sample plane normal, following work by Winkelmann and co-workers (2020). (#587)

  • Method EBSDDetector.plot_pc() to plot projection centers (PCs) in maps, scatter plots or in 3D. (#587)

  • Convenience function kikuchipy.draw.plot_pattern_positions_in_map() to plot positions of selected patterns (typically calibration patterns) in a 2D map. (#587)

  • EBSD signal returned from NORDIF calibration pattern reader tries to add the following new info to the original metadata: Shapes of area and region of interest (ROI), offset of ROI, calibration pattern indices and area overview image. All shapes and coordinates are given both in units of area overview image pixels and scaled according to the pixels in the ROI (actual navigation shape). (#586)

  • Method EBSD.extract_grid() to get a new signal from grid positions evenly spaced in navigation space. (#585)

  • Utility function grid_indices() to extract a smaller 1D or 2D grid of indices from a larger grid. (#585)

  • Seven EBSD master pattern files simulated with EMsoft are available from ebsd_master_pattern() via the data module for download to the local cache: aluminium, nickel, silicon, austenite, ferrite, a chi-phase in steel and a sigma-phase in steel. (#584, #607)

  • Some experimental EBSD datasets are available for download to the local cache via the data module: (50, 50) patterns of (480, 480) pixels from an Si wafer via si_wafer(), ten full Ni datasets of (149, 200) patterns of (60, 60) pixels via ni_gain(number) (number 1-10) (parts of number 1 are used in nickel_ebsd_small()/large()) and the calibration patterns of the ten Ni datasets, ni_gain_calibration(number). (#584, #593, #607)

  • When using the following HyperSpy Signal2D methods via the EBSD class, the class attributes xmap, static_background and detector are handled correctly, which they were not before: inav, isig, crop(), crop_image(). If handling fails, the old behavior is retained. This handling is experimental. (#578)

  • EBSDDetector.crop() method to get a new detector with its shape cropped, also updating the PC values accordingly. (#578)


  • Minimal version of orix set to >= 0.11 and of Numba set to >= 0.55. (#608)

  • Added warnings when trying to perform adaptive histogram equalization on a signal with data in floating type or when some of the data is NaN. (#606)

  • Dask arrays returned from EBSD refinement methods has the number of function evaluations as the second element after the score. (#593)

  • Stricter phase comparison in EBSD refinement. The phase in the crystal map points to refine must have the same name, space group, point group and structure (atoms and lattice) as the master pattern phase. (#593)

  • Passing two crystal maps with identical phases when merging returns a map with one phase instead of two and does not raise a warning, as before. (#593)

  • Exclude documentation and tests from source distribution. (#588)

  • Minimal version of HyperSpy increased to >= 1.7.3. (#585)

  • When binning the navigation dimension(s) with EBSD.rebin(), the class attributes xmap and static_background are set to None and detector.pc is set to [0.5, 0.5, 0.5] in the appropriate navigation shape. If the signal dimension(s) are binned, the static_background is binned similarly while the detector.shape and detector.binning are updated. If this handling of attributes fails, the old behavior is retained. This handling is experimental. (#578)

  • EBSD signal loaded with nickel_ebsd_small() and nickel_ebsd_large() now contain crystal maps with orientations and detectors with PC values found from Hough indexing with PyEBSDIndex followed by orientation and PC refinement. (#578, #584)

  • Minimal version of Matplotlib is 3.5.0 when installing optional dependencies with pip install kikuchipy[viz] since PyVista requires this. (#578)


  • kikuchipy.generators.VirtualBSEGenerator class is deprecated and will be removed in version 0.9. Use kikuchipy.imaging.VirtualBSEImager instead. (#608)

  • The data module functions silicon_ebsd_moving_screen_x(), where “x” is “in”, “out5mm” or “out10mm”, are deprecated and will be removed in v0.9. Use si_ebsd_moving_screen(distance) instead, where distance is 0 (in), 5 or 10. (#607)

  • The PyPI selector viz is replaced by all, which installs all optional dependencies. viz will be removed in version 0.9. Install optional dependencies manually or via pip install kikuchipy[all]. (#590)

  • projections module with classes GnomonicProjection, HesseNormalForm, LambertProjection and SphericalProjection. These will be removed in version 0.9.0, as they are unused internally. If you depend on this module, please open an issue at pyxem/kikuchipy#issues. (#577)


  • mask parameter in EBSD refinement methods; use signal_mask instead. (#577)

  • ebsd_projections module. (#577)


  • Default EBSD.detector.shape is now correct when a detector is not passed upon initialization. (#603)

  • Oxford Instruments .ebsp files of version 4 can now be read. (#602)

  • When loading EBSD patterns from H5OINA files, the detector tilt and binning are available in the returned signal’s detector attribute. (#600)

  • Range of (kinematical) intensities in KikuchiPatternSimulator.plot() maximizes the strongest reflectors (make black) instead of minimizing the weakest reflectors (make white), which was the previous behavior. (#599)

  • Inversion of signal_mask in the normalized cross-correlation and normalized dot product metrics is now done internally, to be in line with the docstrings (does not affect the use of this parameter and metric="ncc" or metric="ndp" in EBSD.dictionary_indexing()). (#593)

  • EBSDDetector.pc_average no longer rounds the PC to three decimals. (#586)

  • Microscope magnification is now read correctly from EDAX h5ebsd files. (#586)

  • kikuchipy h5ebsd reader can read a signal with an EBSD detector with a PC array of different navigation shape than determined from the HDF5 file’s navigation shape (e.g. Scan 1/EBSD/Header/n_columns and n_rows). (#578)

0.7.0 (2022-10-29)#


  • Signal mask passed to EBSD orientation and projection center refinement methods is now applied to the experimental pattern as well. (#573)

  • Dependency imageio needed for reading EBSD patterns in image files. (#570)

  • Reader of an EBSD signal from all images in a directory assuming they are of the same shape and data type. (#570)

  • Reader of an EBSD signal from EDAX TSL’s binary UP1/UP2 file formats. (#569)

  • Ability to project simulate patterns from a master pattern using varying projection centers (PCs) in EBSDMasterPattern.get_patterns(). An example is added to the method to show this. (#567)

  • Allow not setting energy parameter in EBSDMasterPattern.get_patterns(), upon which the highest energy available is used. (#567)

  • Improved handling of custom attributes xmap, detector and static_background in EBSD and hemisphere, phase and projection in EBSD/ECP master pattern classes when calling inherited HyperSpy Signal2D methods as_lazy(), change_dtype(), compute(), deepcopy(), set_signal_type() and squeeze(). (#564)

  • Reader of an electron channelig pattern (ECP) master pattern from an EMsoft HDF5 file into an ECPMasterPattern signal. (#564)

  • Reader of a transmission kikuchi diffraction (TKD) master pattern from an EMsoft HDF5 file into an EBSDMasterPattern signal. (#564)

  • ECPMasterPattern class. (#564)

  • Some internal logging which can be controlled via kikuchipy.set_log_level(). (#564)

  • Reader of an EBSD signal from Oxford Instrument’s h5ebsd format (H5OINA). (#562)

  • Figures of reference frames of other software added to the documentation. (#552)

  • Whether to show progressbars from most signal methods (except indexing and refinement) can be controlled by passing show_progressbar or by setting HyperSpy’s hs.preferences.General.show_progressbar (see their docs for details). (#550)


  • Documentation theme from Furo to PyData, as the growing API reference is easier to navigate with the latter. (#574)

  • Use Rodrigues-Frank vector components (Rx, Ry, Rz) instead of Euler angles in EBSD orientation and projection center refinement methods. This means that if refinement is not directly but a Dask array is returned from any of these methods, the data which previously contained Euler angles now contain these vector components. This change was done to speed up refinement. (#573)

  • Most of the EBSD metadata structure is removed, in an effort to move all relevant data to the attributes xmap, static_background, and detector. (#562)

  • h5ebsd plugin split into one plugin for each h5ebsd format (kikuchipy, EDAX TSL, and Bruker Nano). (#562)

  • EBSDDetector.plot() and PCCalibrationMovingScreen.plot() parameter return_fig_ax renamed to return_figure. (#552)

  • Import modules lazily using the specification in PEP 562. (#551)

  • Minimal version of HyperSpy increased to >= 1.7.1. (#550)

  • progressbar parameter to show_progressbar in functions which accepts a allow_download parameter. If not given, the value is retreived from HyperSpy’s preferences. (#550)


  • mask parameter in EBSD orientation and projection center refinement is deprecated in favor of signal_mask, and will be removed in version 0.8.0. (#573)

  • projections.ebsd_projections module. (#563)


  • EBSDSimulationGenerator and GeometricalEBSDSimulation (use KikuchiPatternSimulator and GeometricalKikuchiPatternSimulation instead) and simulations.features module. (#563)

  • crystallography module. (#563)

  • Options "north" and "south" for property EBSDMasterPattern.hemisphere and in the parameter "hemisphere" in; use "upper" and "lower" instead. (#563)

  • Functions remove_static_background(), remove_dynamic_background() and get_image_quality() from chunk module. (#563)

  • Parameter relative in EBSD.remove_static_background(). (#563)

  • Functions ebsd_metadata() and metadata_nodes() which have been deprecated since v0.5. (#550, #562)

  • Print information emitted from EBSD methods like remove_static_background() is removed. (#550)


  • detector attribute of EBSD signal returned from the NORDIF calibration pattern reader is now an EBSDDetector and not just a dictionary. (#569)

  • Silence dask warning about splitting large chunks in EBSD.dictionary_indexing(). Memory use can be controlled by rechunking the dictionary or setting the rechunk or n_per_iteration parameters. (#567)

0.6.1 (2022-06-17)#


  • Håkon Wiik Ånes


  • Incorrect filtering of zone axes labels in geometrical simulations. (#544)

0.6.0 (2022-06-16)#


  • Håkon Wiik Ånes


  • EBSDMasterPattern.plot_spherical() for plotting a master pattern in the stereographic projection on the 3D sphere. (#536)

  • Projection of master pattern in the stereographic projection to the square Lambert projection via EBSDMasterPattern.to_lambert(). (#536)

  • New package dependencies on pyvista for 3D plotting and on pythreejs for the docs are introduced. (#536)

  • Reduce time and memory use of the following kikuchipy.signals.EBSD methods by using remove_static_background(), remove_dynamic_background() and get_image_quality(). (#527)

  • progressbar parameter to functions downloading external datasets in the data module. (#515)

  • Support for Python 3.10. (#504)

  • EBSD.static_background property for easier access to the background pattern. (#475)


  • Valid EBSDMasterPattern.hemisphere values from "north" and "south" to "upper" and "lower", respectively, to be in line with orix. (#537)

  • Increase minimal version of diffsims to 0.5. (#537)

  • Chunking of EBSD signal navigation dimensions in EBSD.average_neighbour_patterns() to reduce memory use. (#532)

  • Remove requirement that the crystal map used for EBSD refinement has identical step size(s) to the EBSD signal’s navigation axes. This raised an error previously, but now only emits a warning. (#531)

  • Increase minimal version of HyperSpy to 1.7. (#527)

  • Increase minimal version of SciPy to 1.7. (#504)


  • The kikuchipy.simulations.GeometricalEBSDSimulation class is deprecated and will be removed in version 0.7. Obtain kikuchipy.simulations.GeometricalKikuchiPatternSimulation via kikuchipy.simulations.KikuchiPatternSimulator.on_detector() instead. The kikuchipy.simulations.features module is also deprecated and will be removed in version 0.7. Obtain Kikuchi line and zone axis detector/gnomonic coordinates of a simulation via lines_coordinates() and zone_axes_coordinates() instead. (#537)

  • The kikuchipy.generators.EBSDSimulationGenerator class is deprecated and will be removed in version 0.7. Use the kikuchipy.simulations.KikuchiPatternSimulator class instead. (#537)

  • The kikuchipy.crystallography.matrices module is deprecated and will be removed in version 0.7, access the matrices via diffpy.structure.lattice.Lattice attributes instead. (#537)

  • The following functions for processing of pattern chunks in the kikuchipy.pattern.chunk module are deprecated and will be removed in version 0.7: get_image_quality(), remove_dynamic_background() and remove_static_background(). Use the EBSD class for processing of many patterns. (#527, #533 )


  • The relative parameter in kikuchipy.signals.EBSD.remove_static_background(). The parameter is accepted but not used. Passing it after this release will result in an error. (#527)


  • Plotting of geometrical simulation markers on rectangular patterns. (#537)

  • Hopefully prevent EBSD refinement tests using random data to fail on Azure. (#465)

0.5.8 (2022-05-16)#


  • Håkon Wiik Ånes


  • Minimal version of orix is increased to 0.9. (#520)


  • Internal use of orix.vector.Vector3d following orix’ 0.9.0 release. (#520)

0.5.7 (2022-01-10)#


  • Håkon Wiik Ånes


  • EBSD orientation refinement on Windows producing garbage results due to unpredictable behaviour in Numba function which converts Euler triplet to quaternion. (#495)

0.5.6 (2022-01-02)#


  • Håkon Wiik Ånes


  • Convenience function get_rgb_navigator() to create an RGB signal from an RGB image. (#491)


  • Pattern matching notebook to include orientation maps from orix. (#491)

0.5.5 (2021-12-12)#


  • Håkon Wiik Ånes

  • Zhou Xu


  • Not flipping rows and columns when saving non-square patterns to kikuchipy’s h5ebsd format. (#486)

0.5.4 (2021-11-17)#


  • Håkon Wiik Ånes


  • Optional parameters rechunk and chunk_kwargs to EBSD refinement methods to better control possible rechunking of pattern array before refinement. (#470)


  • When EBSD refinement methods don’t immediately compute, they return a dask array instead of a list of delayed instances. (#470)


  • Memory issue in EBSD refinement due to naive use of dask.delayed. Uses map_blocks() instead. (#470)

0.5.3 (2021-11-02)#


  • Håkon Wiik Ånes

  • Zhou Xu


  • Printing of speed (patterns per second) of dictionary indexing and refinement. (#461)

  • Restricted newest version of hyperspy>=1.6.5 due to incompatibility with h5py>=3.5. (#461)


  • Handling of projection centers (PCs): Correct conversion from/to EMsoft’s convention requires binning factor and detector pixel size. Conversion between TSL/Oxford and Bruker conventions correctly uses detector aspect ratio. (#455)

0.5.2 (2021-09-11)#


  • Håkon Wiik Ånes


  • Add gnomonic circles as patches in axes returned from EBSDDetector.plot(). (#445)

  • Restrict lowest supported version of orix to >= 0.7. (#444)

0.5.1 (2021-09-01)#


  • Håkon Wiik Ånes


  • Automatic creation of a release using GitHub Actions, which will simplify and lead to more frequent patch releases. (#433)

0.5.0 (2021-08-31)#


  • Eric Prestat

  • Håkon Wiik Ånes

  • Lars Andreas Hastad Lervik


  • Possibility to specify whether to rechunk experimental and simulated data sets and which data type to use for dictionary indexing. (#419)

  • How to use the new orientation and/or projection center refinements to the pattern matching notebook. (#405)

  • Notebooks to the documentation as shorter or longer “Examples” that don’t fit in the user guide. (#403)

  • Refinement module for EBSD refinement. Allows for the refinement of orientations and/or projection center estimates. (#387)


  • If a custom metric is to be used for dictionary indexing, it must now be a class inheriting from an abstract SimilarityMetric class. This replaces the previous SimilarityMetric class and the make_similarity_metric() function. (#419)

  • Dictionary indexing parameter n_slices to n_per_iteration. (#419)

  • merge_crystal_maps parameter metric to greater_is_better. (#419)

  • orientation_similarity_map parameter normalized is by default False. (#419)

  • Dependency versions for dask >= 2021.8.1, fixing some memory issues encountered after 2021.3.1, and HyperSpy >= 1.6.4. Remove importlib_metadata from package dependencies. (#418)

  • Performance improvements to EBSD dictionary generation, giving a substantial speed-up. (#405)

  • Rename projection methods from project()/iproject() to vector2xy()/xy2vector(). (#405)

  • URLs of user guide topics have an extra “/user_guide/<topic>” added to them. (#403)


  • Custom EBSD metadata, meaning the Acquisition_instrument.SEM.EBSD.Detector and Sample.Phases nodes, as well as the EBSD set_experimental_parameters() and set_phase_parameters() methods. This will be removed in v0.6 The static_background metadata array will become available as an EBSD property. (#428)


  • make_similarity_metric() function is replaced by the need to create a class inheriting from a new abstract SimilarityMetric class, which provides more freedom over preparations of arrays before dictionary indexing. (#419)

  • EBSD.match_patterns() is removed, use EBSD.dictionary_indexing() instead. (#419)

  • kikuchipy.pattern.correlate module. (#419)


  • Allow static background in EBSD metadata to be a Dask array. (#413)

  • Set newest supported version of Sphinx to 4.0.2 so that nbsphinx works. (#403)

0.4.0 (2021-07-08)#


  • Håkon Wiik Ånes


  • Sample tilt about RD can be passed as part of an EBSDDetector. This can be used when projecting parts of master patterns onto a detector. (#381)

  • Reader for uncompressed EBSD patterns stored in Oxford Instrument’s binary .ebsp file format. (#371, #391)

  • Unit testing of docstring examples. (#350)

  • Support for Python 3.9. (#348)

  • Projection/pattern center calibration via the moving screen technique in a kikuchipy.detectors.calibration module. (#322)

  • Three single crystal Si EBSD patterns, from the same sample position but with varying detector distances, to the data module (via external repo). (#320)

  • Reading of NORDIF calibration patterns specified in a setting file into an EBSD signal. (#317)


  • Only return figure from kikuchipy.filters.Window.plot() if desired, also add a colorbar only if desired. (#375)


  • The kikuchipy.pattern.correlate module will be removed in v0.5. Use kikuchipy.indexing.similarity_metrics instead. (#377)

  • Rename the EBSD.match_patterns() method to EBSD.dictionary_indexing(). match_patterns() will be removed in v0.5. (#376)


  • Set minimal requirement of importlib_metadata to v3.6 so Binder can run user guide notebooks with HyperSpy 1.6.3. (#395)

  • Row (y) coordinate array returned with the crystal map from dictionary indexing is correctly sorted. (#392)

  • Deep copying EBSD and EBSDMasterPattern signals carry over, respectively, xmap and detector, and phase, hemisphere and projection properties (#356).

  • Scaling of region of interest coordinates used in virtual backscatter electron imaging to physical coordinates. (#349)

0.3.4 (2021-05-26)#


  • Håkon Wiik Ånes


  • Restricted newest version of dask<=2021.03.1 and pinned orix==0.6.0. (#360)

0.3.3 (2021-04-18)#


  • Håkon Wiik Ånes

  • Ole Natlandsmyr


  • Reading of EBSD patterns from Bruker h5ebsd with a region of interest. (#339)

  • Merging of (typically refined) crystal maps, where either a simulation indices array is not present or the array contains more indices per point than scores. (#335)

  • Bugs in getting plot markers from geometrical EBSD simulation. (#334)

  • Passing a static background pattern to EBSD.remove_static_background() for a non-square detector dataset works. (#331)

0.3.2 (2021-02-01)#


  • Håkon Wiik Ånes


  • Deletion of temporary files saved to temporary directories in user guide. (#312)

  • Pattern matching sometimes failing to generate a crystal map due to incorrect creation of spatial arrays. (#307)

0.3.1 (2021-01-22)#


  • Håkon Wiik Ånes


  • Version link Binder uses to make the Jupyter Notebooks run in the browser. (#301)

0.3.0 (2021-01-22)#

Details of all development associated with this release is listed below and in this GitHub milestone.


  • Håkon Wiik Ånes

  • Lars Andreas Hastad Lervik

  • Ole Natlandsmyr


  • Calculation of an average dot product map, or just the dot product matrices. (#280)

  • A nice gallery to the documentation with links to each user guide page. (#285)

  • Support for writing/reading an EBSD signal with 1 or 0 navigation axes to/from a kikuchipy h5ebsd file. (#276)

  • Better control over dask array chunking when processing patterns. (#275)

  • User guide notebook showing basic pattern matching. (#263)

  • EBSD.detector property storing an EBSDDetector. (#262)

  • Link to Binder in README and in the notebooks for running them in the browser. (#257)

  • Creation of dictionary of dynamically simulated EBSD patterns from a master pattern in the square Lambert projection. (#239)

  • A data module with a small Nickel EBSD data set and master pattern, and a larger EBSD data set downloadable via the module. Two dependencies, pooch and tqdm, are added along with this module. (#236, #237, #243)

  • Pattern matching of EBSD patterns with a dictionary of pre-computed simulated patterns with known crystal orientations, and related useful tools (#231, #233, #234): (1) A framework for creation of similarity metrics used in pattern matching, (2) computation of an orientation similarity map from indexing results, and (3) creation of a multi phase crystal map from single phase maps from pattern matching.

  • EBSD.xmap property storing an orix CrystalMap. (#226)

  • Dependency on the diffsims package for handling of electron scattering and diffraction. (#220)

  • Square Lambert mapping, and its inverse, from points on the unit sphere to a 2D square grid, as implemented in Callahan and De Graef (2013). (#214)

  • Geometrical EBSD simulations, projecting a set of Kikuchi bands and zone axes onto a detector, which can be added to an EBSD signal as markers. (#204, #219, #232)

  • EBSD detector class to handle detector parameters, including detector pixels’ gnomonic coordinates. EBSD reference frame documentation. (#204, #215)

  • Reader for EMsoft’s simulated EBSD patterns returned by their EMEBSD.f90 program. (#202)


  • The feature maps notebook to include how to obtain an average dot product map and dot product matrices for an EBSD signal. (#280)

  • Averaging EBSD patterns with nearest neighbours now rescales to input data type range, thus loosing relative intensities, to avoid clipping intensities. (#280)

  • Dependency requirement of diffsims from >= 0.3 to >= 0.4 (#282)

  • Name of hemisphere axis in EBSDMasterPattern from “y” to “hemisphere”. (#275)

  • Replace Travis CI with GitHub Actions. (#250)

  • The EBSDMasterPattern gets phase, hemisphere and projection properties. (#246)

  • EMsoft EBSD master pattern plugin can read a single energy pattern. Parameter energy_range changed to energy. (240)

  • Migrate user guide from reST files to Jupyter Notebooks converted to HTML with the nbsphinx package. (#236, #237, #244, #245, #279, #245, #279, #281)

  • Move GitHub repository to the pyxem organization. Update relevant URLs. (#198)

  • Allow scikit-image >= 0.16. (#196)

  • Remove language_version in pre-commit config file. (#195)


  • The EBSDMasterPattern and EBSD metadata node Sample.Phases, to be replaced by class attributes. The set_phase_parameters() method is removed from both classes, and the set_simulation_parameters() is removed from the former class. (#246)


  • IndexError in neighbour pattern averaging (#280)

  • Reading of square Lambert projections from EMsoft’s master pattern file now sums contributions from asymmetric positions correctly. (#255)

  • NumPy array creation when calculating window pixel’s distance to the origin is not ragged anymore. (#221)

0.2.2 (2020-05-24)#

This is a patch release that fixes reading of EBSD data sets from h5ebsd files with arbitrary scan group names.


  • Håkon Wiik Ånes


  • Allow reading of EBSD patterns from h5ebsd files with arbitrary scan group names, not just “Scan 1”, “Scan 2”, etc., like was the case before. (#188)

0.2.1 (2020-05-20)#

This is a patch release that enables installing kikuchipy 0.2 from Anaconda and not just PyPI.


  • Håkon Wiik Ånes


  • Use numpy.fft instead of scipy.fft because HyperSpy requires scipy < 1.4 on conda-forge, while scipy.fft was introduced in scipy 1.4. (#180)


  • With the change above, kikuchipy 0.2 should be installable from Anaconda and not just PyPI. (#180)

0.2.0 (2020-05-19)#

Details of all development associated with this release are available here.


  • Håkon Wiik Ånes

  • Tina Bergh


  • Jupyter Notebooks with tutorials and example workflows available.

  • Grey scale and RGB virtual backscatter electron (BSE) images can be easily generated with the VirtualBSEGenerator class. The generator return objects of the new signal class VirtualBSEImage, which inherit functionality from HyperSpy’s Signal2D class. (#170)

  • EBSD master pattern class and reader of master patterns from EMsoft’s EBSD master pattern file. (#159)

  • Python 3.8 support. (#157)

  • The public API has been restructured. The pattern processing used by the EBSD class is available in the kikuchipy.pattern subpackage, and filters/kernels used in frequency domain filtering and pattern averaging are available in the kikuchipy.filters subpackage. (#169)

  • Intensity normalization of scan or single patterns. (#157)

  • Fast Fourier Transform (FFT) filtering of scan or single patterns using SciPy’s fft routines and Connelly Barnes’ filterfft. (#157)

  • Numba dependency to improve pattern rescaling and normalization. (#157)

  • Computing of the dynamic background in the spatial or frequency domain for scan or single patterns. (#157)

  • Image quality (IQ) computation for scan or single patterns based on N. C. K. Lassen’s definition. (#157)

  • Averaging of patterns with nearest neighbours with an arbitrary kernel, e.g. rectangular or Gaussian. (#134)

  • Window/kernel/filter/mask class to handle such things, e.g. for pattern averaging or filtering in the frequency or spatial domain. Available in the kikuchipy.filters module. (#134, #157)


  • Renamed five EBSD methods: static_background_correction to remove_static_background, dynamic_background_correction to remove_dynamic_background, rescale_intensities to rescale_intensity, virtual_backscatter_electron_imaging to plot_virtual_bse_intensity, and get_virtual_image to get_virtual_bse_intensity. (#157, #170)

  • Renamed kikuchipy_metadata to ebsd_metadata. (#169)

  • Source code link in the documentation should point to proper GitHub line. This linkcode_resolve in the file is taken from SciPy. (#157)

  • Read the Docs CSS style. (#157)

  • New logo with a gradient from experimental to simulated pattern (with EMsoft), with a color gradient from the plasma color maps. (#157)

  • Dynamic background correction can be done faster due to Gaussian blurring in the frequency domain to get the dynamic background to remove. (#157)


  • Explicit dependency on scikit-learn (it is imported via HyperSpy). (#168)

  • Dependency on pyxem. Parts of their virtual imaging methods are adapted here—a big thank you to the pyxem/HyperSpy team! (#168)


  • RtD builds documentation with Python 3.8 (fixed problem of missing .egg leading build to fail). (#158)

0.1.3 (2020-05-11)#

kikuchipy is an open-source Python library for processing and analysis of electron backscatter diffraction patterns:

This is a patch release. It is anticipated to be the final release in the 0.1.x series.



  • Static and dynamic background corrections are done at float 32-bit precision, and not integer 16-bit.

  • Chunking of static background pattern.

  • Chunking of patterns in the h5ebsd reader.

0.1.2 (2020-01-09)#

kikuchipy is an open-source Python library for processing and analysis of electron backscatter diffraction patterns:

This is a bug-fix release that ensures, unlike the previous bug-fix release, that necessary files are downloaded when installing from PyPI.

0.1.1 (2020-01-04)#

This is a bug fix release that ensures that necessary files are uploaded to PyPI.

0.1.0 (2020-01-04)#

We’re happy to announce the release of kikuchipy v0.1.0!

kikuchipy is an open-source Python library for processing and analysis of electron backscatter diffraction (EBSD) patterns. The library builds upon the tools for multi-dimensional data analysis provided by the HyperSpy library.

For more information, a user guide, and the full reference API documentation, please visit:

This is the initial pre-release, where things start to get serious… seriously fun!


  • Load EBSD patterns and metadata from the NORDIF binary format (.dat), or Bruker Nano’s or EDAX TSL’s h5ebsd formats (.h5) into an EBSD object, e.g. s, based upon HyperSpy’s Signal2D class, using s = kp.load(). This ensures easy access to patterns and metadata in the attributes and s.metadata, respectively.

  • Save EBSD patterns to the NORDIF binary format (.dat) and our own h5ebsd format (.h5), using Both formats are readable by EMsoft’s NORDIF and EMEBSD readers, respectively.

  • All functionality in kikuchipy can be performed both directly and lazily (except some multivariate analysis algorithms). The latter means that all operations on a scan, including plotting, can be done by loading only necessary parts of the scan into memory at a time. Ultimately, this lets us operate on scans larger than memory using all of our cores.

  • Visualize patterns easily with HyperSpy’s powerful and versatile s.plot(). Any image of the same navigation size, e.g. a virtual backscatter electron image, quality map, phase map, or orientation map, can be used to navigate in. Multiple scans of the same size, e.g. a scan of experimental patterns and the best matching simulated patterns to that scan, can be plotted simultaneously with HyperSpy’s plot_signals().

  • Virtual backscatter electron (VBSE) imaging is easily performed with s.virtual_backscatter_electron_imaging() based upon similar functionality in pyXem. Arbitrary regions of interests can be used, and the corresponding VBSE image can be inspected interactively. Finally, the VBSE image can be obtained in a new EBSD object with vbse = s.get_virtual_image(), before writing the data to an image file in your desired format with matplotlib’s imsave('filename.png',

  • Change scan and pattern size, e.g. by cropping on the detector or extracting a region of interest, by using s.isig or s.inav, respectively. Patterns can be binned (upscaled or downscaled) using s.rebin. These methods are provided by HyperSpy.

  • Perform static and dynamic background correction by subtraction or division with s.static_background_correction() and s.dynamic_background_correction(). For the former correction, relative intensities between patterns can be kept if desired.

  • Perform adaptive histogram equalization by setting an appropriate contextual region (kernel size) with s.adaptive_histogram_equalization().

  • Rescale pattern intensities to desired data type and range using s.rescale_intensities().

  • Multivariate statistical analysis, like principal component analysis and many other decomposition algorithms, can be easily performed with s.decomposition(), provided by HyperSpy.

  • Since the EBSD class is based upon HyperSpy’s Signal2D class, which itself is based upon their BaseSignal class, all functionality available to Signal2D is also available to the EBSD class. See HyperSpy’s user guide ( for details.


  • Håkon Wiik Ånes

  • Tina Bergh