Skip to content
Snippets Groups Projects
Commit b84dfad9 authored by Philipp Arras's avatar Philipp Arras
Browse files

Cosmetics

parent e0f0f20a
Branches
Tags
No related merge requests found
...@@ -21,9 +21,10 @@ ...@@ -21,9 +21,10 @@
# 1D (set mode=0), 2D (mode=1), or on the sphere (mode=2) # 1D (set mode=0), 2D (mode=1), or on the sphere (mode=2)
############################################################################### ###############################################################################
import nifty5 as ift
import numpy as np import numpy as np
import nifty5 as ift
def make_checkerboard_mask(position_space): def make_checkerboard_mask(position_space):
# Checkerboard mask for 2D mode # Checkerboard mask for 2D mode
... ...
......
...@@ -21,9 +21,10 @@ ...@@ -21,9 +21,10 @@
# 1D (set mode=0), 2D (mode=1), or on the sphere (mode=2) # 1D (set mode=0), 2D (mode=1), or on the sphere (mode=2)
############################################################################### ###############################################################################
import nifty5 as ift
import numpy as np import numpy as np
import nifty5 as ift
def exposure_2d(): def exposure_2d():
# Structured exposure for 2D mode # Structured exposure for 2D mode
... ...
......
...@@ -116,10 +116,9 @@ if __name__ == '__main__': ...@@ -116,10 +116,9 @@ if __name__ == '__main__':
# Draw new samples to approximate the KL five times # Draw new samples to approximate the KL five times
for i in range(5): for i in range(5):
# Draw new samples and minimize KL
KL = ift.KL_Energy(position, H, N_samples) KL = ift.KL_Energy(position, H, N_samples)
# Minimize KL
KL, convergence = minimizer(KL) KL, convergence = minimizer(KL)
# Update position
position = KL.position position = KL.position
# Plot current reconstruction # Plot current reconstruction
... ...
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment