diff --git a/.ipynb_checkpoints/ptychoScopy-checkpoint.ipynb b/.ipynb_checkpoints/ptychoScopy-checkpoint.ipynb index e318b6e..c291c34 100644 --- a/.ipynb_checkpoints/ptychoScopy-checkpoint.ipynb +++ b/.ipynb_checkpoints/ptychoScopy-checkpoint.ipynb @@ -349,7 +349,7 @@ }, { "cell_type": "code", - "execution_count": 179, + "execution_count": 200, "id": "8055b802-cf83-4250-aea9-54e3e6b73db0", "metadata": {}, "outputs": [], @@ -469,7 +469,7 @@ " fig.add_trace(go.Scatter(showlegend=False, x=d, y=pctf, marker_color='gray', name='SSB-CTF',))\n", " \n", " fig.add_trace(go.Scatter(x=2*wavelength/(np.sin(semi_angle_corr*omega/1000))/100, y=pctf, marker_color='red', name=str(np.round(semi_angle_corr,2))+ ' mrad',))\n", - " fig.update_xaxes(title_text=\"Real space distance (Å)\", range=[0, 2.5], type=\"log\", zeroline=False)\n", + " fig.update_xaxes(title_text=\"Real space distance (Å)\", range=[0.0001, 2.5], type=\"log\", zeroline=False)\n", " \n", " fig.update_layout(legend=dict(orientation=\"h\",yanchor=\"bottom\",y=0.75,xanchor=\"right\",x=1))\n", " # fig3.update_layout(title={'text': \"CTF\",'y':0.93, 'x':0.12,'xanchor': 'left','yanchor': 'top'})\n", @@ -606,8 +606,8 @@ " \n", " focusdepth = widgets.Label(value = f'Depth of focus (nm) '+ str(np.round(wavelength/(semi_angle_corr/1000)**2/1000,1)), **align3) \n", " \n", - " checks = widgets.VBox([widgets.Label('Final checks'),check1,check2, check3,electron_dose,focusdepth, acquisition_time]) \n", - " checks.layout = widgets.Layout(border='dashed 1px gray',margin='30px 5px 5px 5px', padding='10px 10px 10px 10px')\n", + " \n", + "\n", "\n", "\n", " ### METHODS ########################################## \n", @@ -628,13 +628,26 @@ " fig4.update_layout(xaxis = dict(tickmode = 'array', tickvals = opt.cameralengths()))\n", " fig4.update_layout(width=800, height=225, margin =dict(l=110, r=30, t=30, b=30))\n", " \n", + " \n", + " checks = widgets.VBox([widgets.Label('Final checks'), electron_dose,focusdepth, acquisition_time]) \n", + " checks.layout = widgets.Layout(border='dashed 1px gray',margin='30px 5px 5px 5px', padding='10px 10px 10px 10px')\n", + " \n", + " \n", " ### SHOWING ###\n", " right_column = widgets.VBox([go.FigureWidget(fig),go.FigureWidget(fig5),go.FigureWidget(fig4)])\n", " left_column = widgets.VBox([go.FigureWidget(fig8), go.FigureWidget(fig6)])\n", " display(widgets.HBox([left_column, right_column, checks]))\n", " \n", + " \n", + " \n", + " \n", + " \n", " if method == 'iterative':\n", " \n", + " checks = widgets.VBox([widgets.Label('Final checks'),check1, check2, check3,electron_dose,focusdepth, acquisition_time]) \n", + " checks.layout = widgets.Layout(border='dashed 1px gray',margin='30px 5px 5px 5px', padding='10px 10px 10px 10px')\n", + " \n", + " \n", " ### PROBE WINDOW ##########################################\n", " if beam_diameter < probe_window/2:\n", " color = \"green\"\n", @@ -729,14 +742,14 @@ }, { "cell_type": "code", - "execution_count": 180, + "execution_count": 201, "id": "7937f054-fcd0-4e67-a20f-7696f5903a94", "metadata": {}, "outputs": [ { "data": { "application/vnd.jupyter.widget-view+json": { - "model_id": "3ff56079396a4d12814896dd2a44263f", + "model_id": "a6b2620a5190425a830b6176ed85a285", "version_major": 2, "version_minor": 0 }, diff --git a/calibrations.xlsx b/calibrations.xlsx index c63e2e3..de4d876 100644 Binary files a/calibrations.xlsx and b/calibrations.xlsx differ diff --git a/ptychoScopy.ipynb b/ptychoScopy.ipynb index e318b6e..c291c34 100644 --- a/ptychoScopy.ipynb +++ b/ptychoScopy.ipynb @@ -349,7 +349,7 @@ }, { "cell_type": "code", - "execution_count": 179, + "execution_count": 200, "id": "8055b802-cf83-4250-aea9-54e3e6b73db0", "metadata": {}, "outputs": [], @@ -469,7 +469,7 @@ " fig.add_trace(go.Scatter(showlegend=False, x=d, y=pctf, marker_color='gray', name='SSB-CTF',))\n", " \n", " fig.add_trace(go.Scatter(x=2*wavelength/(np.sin(semi_angle_corr*omega/1000))/100, y=pctf, marker_color='red', name=str(np.round(semi_angle_corr,2))+ ' mrad',))\n", - " fig.update_xaxes(title_text=\"Real space distance (Å)\", range=[0, 2.5], type=\"log\", zeroline=False)\n", + " fig.update_xaxes(title_text=\"Real space distance (Å)\", range=[0.0001, 2.5], type=\"log\", zeroline=False)\n", " \n", " fig.update_layout(legend=dict(orientation=\"h\",yanchor=\"bottom\",y=0.75,xanchor=\"right\",x=1))\n", " # fig3.update_layout(title={'text': \"CTF\",'y':0.93, 'x':0.12,'xanchor': 'left','yanchor': 'top'})\n", @@ -606,8 +606,8 @@ " \n", " focusdepth = widgets.Label(value = f'Depth of focus (nm) '+ str(np.round(wavelength/(semi_angle_corr/1000)**2/1000,1)), **align3) \n", " \n", - " checks = widgets.VBox([widgets.Label('Final checks'),check1,check2, check3,electron_dose,focusdepth, acquisition_time]) \n", - " checks.layout = widgets.Layout(border='dashed 1px gray',margin='30px 5px 5px 5px', padding='10px 10px 10px 10px')\n", + " \n", + "\n", "\n", "\n", " ### METHODS ########################################## \n", @@ -628,13 +628,26 @@ " fig4.update_layout(xaxis = dict(tickmode = 'array', tickvals = opt.cameralengths()))\n", " fig4.update_layout(width=800, height=225, margin =dict(l=110, r=30, t=30, b=30))\n", " \n", + " \n", + " checks = widgets.VBox([widgets.Label('Final checks'), electron_dose,focusdepth, acquisition_time]) \n", + " checks.layout = widgets.Layout(border='dashed 1px gray',margin='30px 5px 5px 5px', padding='10px 10px 10px 10px')\n", + " \n", + " \n", " ### SHOWING ###\n", " right_column = widgets.VBox([go.FigureWidget(fig),go.FigureWidget(fig5),go.FigureWidget(fig4)])\n", " left_column = widgets.VBox([go.FigureWidget(fig8), go.FigureWidget(fig6)])\n", " display(widgets.HBox([left_column, right_column, checks]))\n", " \n", + " \n", + " \n", + " \n", + " \n", " if method == 'iterative':\n", " \n", + " checks = widgets.VBox([widgets.Label('Final checks'),check1, check2, check3,electron_dose,focusdepth, acquisition_time]) \n", + " checks.layout = widgets.Layout(border='dashed 1px gray',margin='30px 5px 5px 5px', padding='10px 10px 10px 10px')\n", + " \n", + " \n", " ### PROBE WINDOW ##########################################\n", " if beam_diameter < probe_window/2:\n", " color = \"green\"\n", @@ -729,14 +742,14 @@ }, { "cell_type": "code", - "execution_count": 180, + "execution_count": 201, "id": "7937f054-fcd0-4e67-a20f-7696f5903a94", "metadata": {}, "outputs": [ { "data": { "application/vnd.jupyter.widget-view+json": { - "model_id": "3ff56079396a4d12814896dd2a44263f", + "model_id": "a6b2620a5190425a830b6176ed85a285", "version_major": 2, "version_minor": 0 },