<s>
CrysTBox	B-Application
(	O
Crystallographic	O
Tool	O
Box	O
)	O
is	O
a	O
suite	B-Application
of	O
computer	O
tools	O
designed	O
to	O
accelerate	O
material	O
research	O
based	O
on	O
transmission	O
electron	O
microscope	O
images	O
via	O
highly	O
accurate	O
automated	B-Application
analysis	O
and	O
interactive	O
visualization	B-Application
.	O
</s>
<s>
Relying	O
on	O
artificial	B-Application
intelligence	I-Application
and	O
computer	B-Application
vision	I-Application
,	O
CrysTBox	B-Application
makes	O
routine	O
crystallographic	O
analyses	O
simpler	O
,	O
faster	O
and	O
more	O
accurate	O
compared	O
to	O
human	O
evaluators	O
.	O
</s>
<s>
The	O
high	O
level	O
of	O
automation	B-Application
together	O
with	O
sub-pixel	O
precision	O
and	O
interactive	O
visualization	B-Application
makes	O
the	O
quantitative	O
crystallographic	O
analysis	O
accessible	O
even	O
for	O
non-crystallographers	O
allowing	O
for	O
an	O
interdisciplinary	O
research	O
.	O
</s>
<s>
CrysTBox	B-Application
is	O
being	O
developed	O
in	O
the	O
Laboratory	O
of	O
electron	O
microscopy	O
at	O
the	O
Institute	O
of	O
Physics	O
of	O
the	O
Czech	O
Academy	O
of	O
Sciences	O
.	O
</s>
<s>
As	O
of	O
2022	O
,	O
the	O
suite	B-Application
has	O
been	O
deployed	O
at	O
research	O
and	O
educational	O
facilities	O
in	O
more	O
than	O
90	O
countries	O
supporting	O
research	O
of	O
ETH	O
Zurich	O
,	O
Lawrence	O
Berkeley	O
National	O
Laboratory	O
,	O
Max	O
Planck	O
Institutes	O
,	O
Chinese	O
Academy	O
of	O
Sciences	O
,	O
Fraunhofer	O
Institutes	O
or	O
Oxford	O
University	O
.	O
</s>
<s>
As	O
a	O
scientific	O
tool	O
,	O
CrysTBox	B-Application
suite	B-Application
is	O
freely	O
available	O
for	O
academic	O
purposes	O
,	O
it	O
supports	O
file	O
formats	O
widely	O
used	O
in	O
the	O
community	O
and	O
offers	O
interconnection	O
with	O
other	O
scientific	O
software	O
.	O
</s>
<s>
CrysTBox	B-Application
is	O
freely	O
available	O
on	O
demand	O
for	O
non-commercial	O
use	O
by	O
non-commercial	O
subjects	O
.	O
</s>
<s>
The	O
only	O
safe	O
way	O
to	O
download	O
CrysTBox	B-Application
installers	B-Operating_System
is	O
via	O
a	O
request	O
form	O
on	O
the	O
official	O
website	O
.	O
</s>
<s>
Commercial	O
use	O
is	O
not	O
allowed	O
due	O
to	O
the	O
license	O
of	O
MATLAB	B-Language
used	O
for	O
CrysTBox	B-Application
compilation	B-Language
.	O
</s>
<s>
Besides	O
education	O
,	O
CrysTBox	B-Application
is	O
mainly	O
used	O
in	O
research	O
with	O
fields	O
of	O
application	O
spanning	O
from	O
nuclear	O
research	O
to	O
archaeology	O
and	O
paleontology	O
.	O
</s>
<s>
Among	O
others	O
,	O
the	O
suite	B-Application
was	O
employed	O
in	O
development	O
of	O
additive	O
manufacturing	O
(	O
including	O
3D	O
printed	O
biodegradable	O
alloys	O
,	O
metallic	O
glass	O
or	O
high-entropy	O
alloys	O
)	O
,	O
resistant	O
coatings	O
,	O
laser	O
shock	O
peening	O
,	O
water	O
cleaning	O
technologies	O
or	O
characterization	O
of	O
50	O
million	O
years	O
old	O
flint	B-Language
.	O
</s>
<s>
Institutions	O
whose	O
research	O
was	O
supported	O
by	O
CrysTBox	B-Application
include	O
educational	O
facilities	O
such	O
as	O
ETH	O
Zurich	O
,	O
University	O
of	O
California	O
,	O
Uppsala	O
University	O
,	O
Oxford	O
University	O
,	O
University	O
of	O
Waterloo	O
,	O
Indian	O
Institute	O
of	O
Technology	O
,	O
Nanyang	O
Technological	O
University	O
or	O
University	O
of	O
Tokyo	O
as	O
well	O
as	O
research	O
institutes	O
like	O
Max	O
Planck	O
Institutes	O
,	O
Chinese	O
Academy	O
of	O
Sciences	O
,	O
Fraunhofer	O
Institutes	O
or	O
US	O
national	O
laboratories	O
(	O
NL	O
)	O
such	O
as	O
Oak	O
Ridge	O
NL	O
,	O
Lawrence	O
Berkeley	O
NL	O
,	O
Idaho	O
NL	O
and	O
Lawrence	O
Livermoore	O
NL	O
.	O
</s>
<s>
CrysTBox	B-Application
is	O
compiled	B-Language
to	O
a	O
stand-alone	O
installers	B-Operating_System
using	O
MATLAB	B-Language
Compiler	B-Language
.	O
</s>
<s>
Therefore	O
,	O
1-2	O
GB	O
of	O
MATLAB	B-Language
libraries	B-Library
are	O
installed	O
together	O
with	O
the	O
toolbox	O
.	O
</s>
<s>
This	O
allows	O
for	O
a	O
real-time	O
response	O
to	O
user	O
interaction	O
,	O
but	O
it	O
does	O
not	O
cover	O
advanced	O
diffraction	O
features	O
like	O
double	O
diffraction	O
covered	O
by	O
dynamical	O
diffraction	O
theory	O
,	O
even	O
though	O
some	O
phenomena	O
caused	O
by	O
multiple	O
electron-matter	O
interactions	O
are	O
visualized	O
by	O
CrysTBox	B-Application
-	O
for	O
instance	O
Kikuchi	O
lines	O
.	O
</s>
<s>
The	O
analytical	O
tools	O
provide	O
correction	O
for	O
scale	O
calibration	B-General_Concept
imperfections	O
,	O
but	O
does	O
not	O
provide	O
adjustment	O
for	O
image	O
distortions	O
such	O
as	O
elliptical	O
distortion	O
.	O
</s>
<s>
In	O
order	O
to	O
visualize	O
functional	O
relations	O
and	O
provide	O
better	O
understanding	O
of	O
experimental	B-General_Concept
data	I-General_Concept
,	O
the	O
graphical	B-Application
interface	I-Application
emphasize	O
user	O
interactivity	O
and	O
functional	O
interconnection	O
.	O
</s>
<s>
There	O
are	O
two	O
visualization	B-Application
tools	O
in	O
the	O
suite	B-Application
:	O
one	O
depicting	O
single	O
material	O
while	O
another	O
being	O
focused	O
on	O
intergrowths	O
of	O
two	O
different	O
materials	O
.	O
</s>
<s>
stereographic	O
projection	B-Algorithm
(	O
projection	B-Algorithm
of	O
3D	O
space	O
of	O
crystallographic	O
planes	O
and	O
directions	O
to	O
2D	O
)	O
,	O
</s>
<s>
inverse	O
pole	O
figure	O
(	O
defined	O
part	O
of	O
stereographic	O
projection	B-Algorithm
)	O
.	O
</s>
<s>
Graphical	B-Application
user	I-Application
interface	I-Application
provides	O
user	O
with	O
two	O
interactive	O
views	O
side	O
by	O
side	O
.	O
</s>
<s>
These	O
views	O
can	O
display	O
arbitrary	O
combination	O
of	O
the	O
four	O
aforementioned	O
visualization	B-Application
modes	O
allowing	O
to	O
perceive	O
their	O
mutual	O
relations	O
.	O
</s>
<s>
Such	O
interconnections	O
are	O
implemented	O
for	O
each	O
pair	O
of	O
the	O
four	O
available	O
visualization	B-Application
modes	O
.	O
</s>
<s>
The	O
electronic	O
visualization	B-Application
allows	O
to	O
simplify	O
understanding	O
of	O
widely	O
used	O
,	O
yet	O
less	O
intuitive	O
representations	O
such	O
as	O
the	O
inverse	O
pole	O
figure	O
.	O
</s>
<s>
For	O
instance	O
by	O
drawing	O
the	O
coloured	O
triangle	O
of	O
the	O
inverse	O
pole	O
figure	O
into	O
the	O
stereographic	O
projection	B-Algorithm
or	O
to	O
the	O
more	O
intuitive	O
3D	O
atomic	O
structure	O
.	O
</s>
<s>
The	O
ifaceViewer	O
allows	O
for	O
visualization	B-Application
of	O
two	O
misoriented	O
materials	O
and	O
their	O
interface	O
such	O
as	O
crystal	O
twins	O
or	O
grain	O
boundaries	O
.	O
</s>
<s>
wire-frame	B-Algorithm
model	I-Algorithm
of	O
both	O
unit	O
cells	O
,	O
</s>
<s>
cross	B-Application
section	I-Application
of	O
the	O
interface	O
,	O
</s>
<s>
CrysTBox	B-Application
offers	O
tools	O
for	O
automated	B-Application
processing	O
of	O
diffraction	O
patterns	O
and	O
high-resolution	B-Algorithm
transmission	O
electron	O
microscope	O
images	O
.	O
</s>
<s>
Since	O
the	O
tools	O
employ	O
algorithms	O
of	O
artificial	B-Application
intelligence	I-Application
and	O
computer	B-Application
vision	I-Application
,	O
they	O
are	O
designed	O
to	O
require	O
minimal	O
operator	O
effort	O
providing	O
higher	O
accuracy	O
compared	O
to	O
manual	O
evaluation	O
.	O
</s>
<s>
Despite	O
the	O
high	O
level	O
of	O
automation	B-Application
,	O
the	O
user	O
is	O
able	O
to	O
control	O
the	O
whole	O
process	O
and	O
perform	O
individual	O
steps	O
manually	O
if	O
needed	O
.	O
</s>
<s>
DiffractGUI	O
allows	O
for	O
an	O
automated	B-Application
analysis	O
of	O
diffraction	O
patterns	O
and	O
high-resolution	B-Algorithm
images	O
of	O
single	O
crystal	O
or	O
limited	O
number	O
of	O
crystallites	O
.	O
</s>
<s>
high-resolution	B-Algorithm
image	O
,	O
</s>
<s>
Preprocessing	B-General_Concept
with	O
accordance	O
to	O
the	O
settings	O
and	O
image	O
nature	O
(	O
resolution	B-Algorithm
and	O
noise	O
reduction	O
,	O
Fourier	B-Algorithm
transform	I-Algorithm
for	O
direct	O
space	O
images	O
etc	O
.	O
</s>
<s>
Detection	B-General_Concept
of	O
diffraction	O
reflections	O
at	O
various	O
scales	O
(	O
difference	B-Algorithm
of	I-Algorithm
Gaussians	I-Algorithm
typically	O
used	O
for	O
spot	O
detection	B-General_Concept
,	O
Hough	B-Algorithm
transform	I-Algorithm
for	O
CBED	O
disk	O
detection	B-General_Concept
)	O
.	O
</s>
<s>
The	O
strongest	O
detections	O
are	O
selected	O
across	O
the	O
scale	B-Algorithm
space	I-Algorithm
.	O
</s>
<s>
A	O
regular	O
lattice	O
is	O
fit	B-Algorithm
to	O
the	O
set	O
of	O
the	O
strongest	O
detections	O
using	O
RANSAC	B-Algorithm
algorithm	O
.	O
</s>
<s>
RingGUI	O
allows	O
for	O
an	O
automated	B-Application
processing	O
of	O
ring	O
diffraction	O
images	O
of	O
polycrystalline	O
or	O
powder	O
samples	O
.	O
</s>
<s>
With	O
known	O
material	O
,	O
it	O
can	O
assist	O
in	O
microscope	O
calibration	B-General_Concept
.	O
</s>
<s>
beam-stopper	O
detection	B-General_Concept
,	O
</s>
<s>
The	O
procedure	O
is	O
based	O
on	O
an	O
automated	B-Application
extraction	O
of	O
the	O
intensity	O
profile	O
across	O
the	O
diffracted	O
disk	O
in	O
the	O
following	O
steps	O
:	O
</s>
<s>
diffraction	O
disk	O
radius	O
is	O
determined	O
using	O
multi-scale	O
Hough	B-Algorithm
transform	I-Algorithm
,	O
</s>
<s>
the	O
profile	O
across	O
the	O
diffracted	O
disk	O
is	O
matched	B-Language
with	O
a	O
series	O
of	O
profiles	O
automatically	O
simulated	O
for	O
given	O
material	O
,	O
reflection	O
and	O
specified	O
thickness	O
range	O
.	O
</s>
<s>
This	O
allows	O
the	O
user	O
to	O
verify	O
correctness	O
of	O
the	O
automated	B-Application
estimate	O
and	O
easily	O
check	O
the	O
similarity	O
of	O
other	O
intensity	O
profiles	O
within	O
the	O
specified	O
thickness	O
range	O
.	O
</s>
<s>
It	O
allows	O
to	O
generate	O
2D	O
maps	O
of	O
various	O
crystallographic	O
quantities	O
using	O
high-resolution	B-Algorithm
images	O
.	O
</s>
<s>
Since	O
the	O
geometric	O
phase	O
analysis	O
is	O
performed	O
in	O
frequency	O
domain	O
,	O
the	O
high-resolution	B-Algorithm
image	O
needs	O
to	O
be	O
transformed	O
into	O
frequential	O
representation	O
using	O
Fourier	B-Algorithm
transform	I-Algorithm
.	O
</s>
<s>
After	O
performing	O
desired	O
calculations	O
,	O
the	O
frequential	O
representation	O
can	O
be	O
transformed	O
back	O
to	O
the	O
original	O
spatial	O
domain	O
using	O
inverse	O
Fourier	B-Algorithm
transform	I-Algorithm
.	O
</s>
<s>
If	O
it	O
is	O
filtered	O
so	O
that	O
only	O
the	O
information	O
from	O
a	O
region	O
close	O
to	O
a	O
particular	O
diffraction	O
spot	O
is	O
used	O
(	O
the	O
rest	O
is	O
set	O
to	O
zero	O
)	O
,	O
a	O
filtered	O
direct	O
image	O
obtained	O
by	O
inverse	O
Fourier	B-Algorithm
transform	I-Algorithm
then	O
depicts	O
only	O
the	O
planes	O
corresponding	O
to	O
the	O
selected	O
diffraction	O
spot	O
.	O
</s>
<s>
Moreover	O
,	O
due	O
to	O
its	O
complex	O
nature	O
,	O
the	O
frequential	O
image	O
can	O
be	O
used	O
to	O
calculate	O
amplitude	B-Application
and	O
phase	O
.	O
</s>
<s>
Graphical	B-Application
user	I-Application
interface	I-Application
of	O
gpaGUI	O
is	O
vertically	O
divided	O
into	O
two	O
halves	O
,	O
each	O
of	O
which	O
contains	O
:	O
</s>
<s>
Visualization	B-Application
of	O
a	O
selected	O
quantity	O
(	O
input	O
image	O
,	O
filtered	O
image	O
or	O
one	O
of	O
the	O
maps	O
mentioned	O
above	O
)	O
allowing	O
to	O
select	O
point	O
of	O
interest	O
or	O
region	B-Algorithm
of	I-Algorithm
interest	I-Algorithm
for	O
further	O
analysis	O
.	O
</s>
<s>
Results	O
of	O
detailed	O
analysis	O
of	O
point	O
or	O
region	B-Algorithm
of	I-Algorithm
interest	I-Algorithm
.	O
</s>
<s>
If	O
analysis	O
of	O
broader	O
area	O
is	O
needed	O
,	O
a	O
polygonal	O
region	O
can	O
be	O
outlined	O
in	O
the	O
map	O
allowing	O
to	O
enumerate	O
its	O
statistical	O
details	O
:	O
mean	O
,	O
standard	B-General_Concept
deviation	I-General_Concept
,	O
median	O
,	O
minimum	O
,	O
maximum	O
and	O
total	O
area	O
of	O
the	O
polygon	O
.	O
</s>
