Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions examples/01_Hexagonal_tiling.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
],
"metadata": {
"kernelspec": {
"display_name": ".pyenv38",
"display_name": ".venv",
"language": "python",
"name": "python3"
},
Expand All @@ -113,7 +113,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.12"
"version": "3.11.2"
}
},
"nbformat": 4,
Expand Down
4 changes: 2 additions & 2 deletions examples/02_Brillouin_zoning.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@
],
"metadata": {
"kernelspec": {
"display_name": ".pyenv38",
"display_name": ".venv",
"language": "python",
"name": "python3"
},
Expand All @@ -291,7 +291,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.12"
"version": "3.11.2"
}
},
"nbformat": 4,
Expand Down
4 changes: 2 additions & 2 deletions examples/03_preprocessing.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@
],
"metadata": {
"kernelspec": {
"display_name": ".pyenv38",
"display_name": ".venv",
"language": "python",
"name": "python3"
},
Expand All @@ -224,7 +224,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.12"
"version": "3.11.2"
},
"pycharm": {
"stem_cell": {
Expand Down
44 changes: 32 additions & 12 deletions examples/04_mpes_reconstruction_mrf.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,17 @@
"import os"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"import tensorflow as tf\n",
"\n",
"tf.config.list_physical_devices('GPU')"
]
},
{
"cell_type": "code",
"execution_count": null,
Expand All @@ -54,7 +65,12 @@
"E = data['E']\n",
"kx = data['kx']\n",
"ky = data['ky']\n",
"I = data['V']"
"I_1 = data['V']\n",
"\n",
"I_2 = np.tile(I_1, (10, 1, 1, 1))\n",
"I = np.transpose(I_2, axes=(1, 2, 3, 0))\n",
"\n",
"t = np.linspace(0, 9, 10)"
]
},
{
Expand All @@ -64,7 +80,11 @@
"outputs": [],
"source": [
"# Create MRF model\n",
"mrf = MrfRec(E=E, kx=kx, ky=ky, I=I, eta=.12)\n",
"mrf = MrfRec(E=E, kx=kx, ky=ky, I=I, delay = t, eta=.12)\n",
"#mrf.symmetrizeI(mirror=False)\n",
"#mrf.symmetrizeI(rotational=False)\n",
"#mrf.normalizeI(kernel_size=(30, 30, 40), n_bins=256, clip_limit=0.1, use_gpu=True)\n",
"#mrf.smoothenI(sigma=(.8, .8, 1.))\n",
"mrf.I_normalized = True"
]
},
Expand Down Expand Up @@ -99,8 +119,8 @@
"outputs": [],
"source": [
"# Plot slices with initialiation to check offset and scale\n",
"mrf.plotI(ky=0, plotBandInit=True, cmapName='coolwarm')\n",
"mrf.plotI(kx=0, plotBandInit=True, cmapName='coolwarm')"
"mrf.plotI(ky=0, time = 0, plotBandInit=True, cmapName='coolwarm')\n",
"mrf.plotI(kx=0, time = 0, plotBandInit=True, cmapName='coolwarm')"
]
},
{
Expand All @@ -120,7 +140,7 @@
"source": [
"# Run optimization to perform reconstruction\n",
"eta = .1\n",
"n_epochs = 150\n",
"n_epochs = 100\n",
"\n",
"mrf.eta = eta\n",
"mrf.iter_para(n_epochs)"
Expand All @@ -135,11 +155,11 @@
"outputs": [],
"source": [
"# Plot results\n",
"mrf.plotBands()\n",
"mrf.plotI(ky=0, plotBand=True, plotBandInit=True, plotSliceInBand=False, cmapName='coolwarm')\n",
"mrf.plotI(ky=0.5, plotBand=True, plotBandInit=True, plotSliceInBand=False, cmapName='coolwarm')\n",
"mrf.plotI(kx=0, plotBand=True, plotBandInit=True, plotSliceInBand=False, cmapName='coolwarm')\n",
"mrf.plotI(kx=0.5, plotBand=True, plotBandInit=True, plotSliceInBand=False, cmapName='coolwarm')"
"#mrf.plotBands()\n",
"mrf.plotI(ky=0, plotBand=True, plotBandInit=True, plotSliceInBand=False, cmapName='coolwarm', time = 0)\n",
"mrf.plotI(ky=0.5, plotBand=True, plotBandInit=True, plotSliceInBand=False, cmapName='coolwarm', time = 0)\n",
"mrf.plotI(kx=0, plotBand=True, plotBandInit=True, plotSliceInBand=False, cmapName='coolwarm', time = 0)\n",
"mrf.plotI(kx=0.5, plotBand=True, plotBandInit=True, plotSliceInBand=False, cmapName='coolwarm', time = 0)"
]
},
{
Expand All @@ -163,7 +183,7 @@
],
"metadata": {
"kernelspec": {
"display_name": ".pyenv38",
"display_name": ".venv",
"language": "python",
"name": "python3"
},
Expand All @@ -177,7 +197,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.12"
"version": "3.11.2"
}
},
"nbformat": 4,
Expand Down
4 changes: 2 additions & 2 deletions examples/05_synthetic_data_and_initial_conditions.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@
],
"metadata": {
"kernelspec": {
"display_name": ".pyenv38",
"display_name": ".venv",
"language": "python",
"name": "python3"
},
Expand All @@ -389,7 +389,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.12"
"version": "3.11.2"
}
},
"nbformat": 4,
Expand Down
Loading