regular backup
This commit is contained in:
parent
d84e6da902
commit
aa13f41dd9
@ -168,6 +168,8 @@ class ImageAnalyser():
|
|||||||
if span is None:
|
if span is None:
|
||||||
span = self._span
|
span = self._span
|
||||||
|
|
||||||
|
if not x in
|
||||||
|
|
||||||
x_start = int(center[0] - span[0] / 2)
|
x_start = int(center[0] - span[0] / 2)
|
||||||
x_end = int(center[0] + span[0] / 2)
|
x_end = int(center[0] + span[0] / 2)
|
||||||
y_end = int(center[1] + span[1] / 2)
|
y_end = int(center[1] + span[1] / 2)
|
||||||
@ -193,7 +195,14 @@ class ImageAnalyser():
|
|||||||
dataSet[key].attrs['x_span'] = span[0]
|
dataSet[key].attrs['x_span'] = span[0]
|
||||||
dataSet[key].attrs['y_span'] = span[1]
|
dataSet[key].attrs['y_span'] = span[1]
|
||||||
|
|
||||||
return dataSet.isel(x=slice(x_start, x_end), y=slice(y_start, y_end))
|
res = dataSet.isel(x=slice(x_start, x_end), y=slice(y_start, y_end))
|
||||||
|
res = res.assign_coords(
|
||||||
|
{
|
||||||
|
'x': np.linspace(x_start, x_end - 1, span[0]),
|
||||||
|
'y': np.linspace(y_start, y_end - 1, span[1]),
|
||||||
|
}
|
||||||
|
)
|
||||||
|
return res
|
||||||
|
|
||||||
def get_OD(self, imageAtom, imageBackground, imageDrak):
|
def get_OD(self, imageAtom, imageBackground, imageDrak):
|
||||||
"""Calculate the OD image for absorption imaging.
|
"""Calculate the OD image for absorption imaging.
|
||||||
|
299
AtomLoss.ipynb
299
AtomLoss.ipynb
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user