Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding moire lattices #511

Closed
wants to merge 43 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
dd9faa2
changes to crystal phase
Quantumstud Feb 6, 2023
35556a8
adds test_Crystal.py skeleton
bsavitzky Feb 6, 2023
8132882
allows mp-api >= 0.24.1
bsavitzky Feb 6, 2023
4028c0d
add test data, test .from_CIF
bsavitzky Feb 6, 2023
70e0af8
updates
bsavitzky Feb 6, 2023
0e69796
updates
bsavitzky Feb 6, 2023
5c55c5b
crystal + crystal phase tests written + passing
bsavitzky Feb 7, 2023
54a3300
finishes moving orientation_map -> crystal. nbs pass, tests pass
bsavitzky Feb 7, 2023
5bdfceb
Merge branch 'crystal_phase' into crystal_phase
bsavitzky Feb 7, 2023
d558e94
change the continue
Quantumstud Feb 8, 2023
b19e530
Merge branch 'crystal_phase' of github.com:Quantumstud/py4DSTEM into …
Quantumstud Feb 8, 2023
6d8687b
Merge branch 'dev' into crystal_phase
cophus Feb 16, 2023
4c1dff1
refactor of phase matching
cophus Feb 17, 2023
2156d07
Phase mapping plus plotting functions
cophus Feb 17, 2023
8a78ac5
Merge pull request #397 from cophus/crystal_phase
cophus Feb 17, 2023
cc7c4d1
crystal_phase_safe_keep
Quantumstud Feb 17, 2023
a1f8a40
sync with the crystal phase of py4dstem upstream repo
Quantumstud Feb 17, 2023
ae91f24
change class variable name
Quantumstud Feb 19, 2023
d00e389
Merge pull request #398 from Quantumstud/crystal_phase
bsavitzky Feb 22, 2023
73e495b
Testing normalization by total DF peak intensity
cophus Mar 7, 2023
37e416d
Merge pull request #402 from cophus/crystal_phase
cophus Mar 7, 2023
e6b9f2e
updates
bsavitzky Mar 14, 2023
81f7999
Merge branch 'crystal_phase' of git+ssh://github.com/py4dstem/py4DSTE…
bsavitzky Mar 14, 2023
1491768
merge dev
bsavitzky Jul 14, 2023
20bb94f
bugfix
bsavitzky Jul 14, 2023
7b9d330
bugfix
bsavitzky Jul 14, 2023
b78e625
Merge dev into crystal_phase
cophus Aug 9, 2023
e62642d
Fixing merge conflicts
cophus Aug 9, 2023
0a5e7a2
merge dev
cophus Aug 9, 2023
fa4736f
updates to polardata
cophus Aug 9, 2023
e00a415
Merge remote-tracking branch 'cophus/polardata' into polardata
cophus Aug 9, 2023
4e1be96
Fixing merge conflicts
cophus Aug 9, 2023
46effbb
Merge conflict fixing
cophus Aug 9, 2023
a9c941d
Fixing the phase mapping module
cophus Aug 10, 2023
0ae8d72
Cleaning up
cophus Aug 14, 2023
fe79712
Fixing CUDA disk detection
cophus Aug 15, 2023
453ee45
Merge remote-tracking branch 'origin/dev' into crystal_phase
cophus Aug 19, 2023
ce2c095
Merge remote-tracking branch 'cophus/crystal_phase' into crystal_phase
cophus Aug 19, 2023
20007d8
Merge remote-tracking branch 'origin/polardata' into crystal_phase
cophus Aug 20, 2023
0ea5e71
Merge branch 'polardata' into crystal_phase
cophus Aug 20, 2023
c97b738
Merge remote-tracking branch 'origin/dev' into crystal_phase
cophus Aug 28, 2023
6e9817b
Adding moire lattice generation and plotting
cophus Aug 29, 2023
886cab4
Merge remote-tracking branch 'origin/dev' into crystal_phase
cophus Aug 29, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions py4DSTEM/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
from py4DSTEM.version import __version__
from emdfile import tqdmnd

# test paths
from os.path import dirname,join
_TESTPATH = join(dirname(__file__), "test/unit_test_data")



### io

Expand Down Expand Up @@ -79,7 +84,16 @@

# TODO - config .toml

# <<<<<<< HEAD


# classes

# from py4DSTEM.process.diffraction import Crystal

# =======
# testing
from os.path import dirname, join

_TESTPATH = join(dirname(__file__), "../test/unit_test_data")
# >>>>>>> dev
16 changes: 12 additions & 4 deletions py4DSTEM/braggvectors/diskdetection.py
Original file line number Diff line number Diff line change
Expand Up @@ -553,8 +553,12 @@ def _find_Bragg_disks_CUDA_unbatched(
)

# Populate a BraggVectors instance and return
braggvectors = BraggVectors(datacube.Rshape, datacube.Qshape)
braggvectors._v_uncal = peaks
braggvectors = BraggVectors(
datacube.Rshape,
datacube.Qshape,
name = peaks.name)
braggvectors.set_raw_vectors(peaks)

return braggvectors


Expand Down Expand Up @@ -598,8 +602,12 @@ def _find_Bragg_disks_CUDA_batched(
)

# Populate a BraggVectors instance and return
braggvectors = BraggVectors(datacube.Rshape, datacube.Qshape)
braggvectors._v_uncal = peaks
braggvectors = BraggVectors(
datacube.Rshape,
datacube.Qshape,
name = peaks.name)
braggvectors.set_raw_vectors(peaks)

return braggvectors


Expand Down
18 changes: 9 additions & 9 deletions py4DSTEM/datacube/virtualimage.py
Original file line number Diff line number Diff line change
Expand Up @@ -314,15 +314,15 @@ def position_detector(
self,
mode,
geometry,
data=None,
centered=None,
calibrated=None,
shift_center=False,
scan_position=None,
invert=False,
color="r",
alpha=0.7,
**kwargs,
data = None,
centered = None,
calibrated = None,
shift_center = False,
scan_position = None,
invert = False,
color = 'c',
alpha = 0.7,
**kwargs
):
"""
Position a virtual detector by displaying a mask over a diffraction
Expand Down
14 changes: 14 additions & 0 deletions py4DSTEM/preprocess/preprocess.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,20 @@ def bin_data_diffraction(datacube, bin_factor, dtype=None):
Qpixsize = datacube.calibration.get_Q_pixel_size() * bin_factor
Qpixunits = datacube.calibration.get_Q_pixel_units()

# set dims
datacube.set_dim(
2,
[0,Qpixsize],
units = Qpixunits,
name = 'Qx'
)
datacube.set_dim(
3,
[0,Qpixsize],
units = Qpixunits,
name = 'Qy'
)

datacube.set_dim(2, [0, Qpixsize], units=Qpixunits, name="Qx")
datacube.set_dim(3, [0, Qpixsize], units=Qpixunits, name="Qy")

Expand Down
Loading
Loading