mirror of
https://gitlab.science.ru.nl/mthesis-edeboone/m.internship-documentation.git
synced 2024-11-22 15:03:35 +01:00
Figure: src: beacon field sizing
This commit is contained in:
parent
5e9f5d5621
commit
47016f867e
2 changed files with 37 additions and 8 deletions
|
@ -47,20 +47,31 @@ field_single_center_time_nomax.%: src/beacon_field.py
|
||||||
$< --time $@ single-center --max-rms 0
|
$< --time $@ single-center --max-rms 0
|
||||||
|
|
||||||
field_three: \
|
field_three: \
|
||||||
|
field_three_left \
|
||||||
|
field_three_center \
|
||||||
|
#
|
||||||
|
field_three_left: \
|
||||||
field_three_left_time.pdf field_three_left_time.png \
|
field_three_left_time.pdf field_three_left_time.png \
|
||||||
field_three_left_phase.pdf field_three_left_phase.png \
|
field_three_left_phase.pdf field_three_left_phase.png \
|
||||||
|
field_three_left_time_nomax.pdf field_three_left_time_nomax.png \
|
||||||
|
field_three_left_phase_nomax.pdf field_three_left_phase_nomax.png \
|
||||||
|
#
|
||||||
|
field_three_center: \
|
||||||
field_three_center_time.pdf field_three_center_time.png \
|
field_three_center_time.pdf field_three_center_time.png \
|
||||||
field_three_center_phase.pdf field_three_center_phase.png \
|
field_three_center_phase.pdf field_three_center_phase.png \
|
||||||
field_three_left_time_nomax.pdf field_three_left_time_nomax.png \
|
|
||||||
field_three_center_time_nomax.pdf field_three_center_time_nomax.png \
|
field_three_center_time_nomax.pdf field_three_center_time_nomax.png \
|
||||||
|
field_three_center_phase_nomax.pdf field_three_center_phase_nomax.png \
|
||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
field_three_left_time.%: src/beacon_field.py
|
field_three_left_time.%: src/beacon_field.py
|
||||||
$< --time $@ three-left
|
$< --time $@ three-left
|
||||||
field_three_left_phase.%: src/beacon_field.py
|
|
||||||
$< --phase $@ three-left
|
|
||||||
field_three_left_time_nomax.%: src/beacon_field.py
|
field_three_left_time_nomax.%: src/beacon_field.py
|
||||||
$< --time $@ three-left --max-rms 0
|
$< --time $@ three-left --max-rms 0
|
||||||
|
field_three_left_phase.%: src/beacon_field.py
|
||||||
|
$< --phase $@ three-left
|
||||||
|
field_three_left_phase_nomax.%: src/beacon_field.py
|
||||||
|
$< --phase $@ three-left --max-rms 0
|
||||||
|
|
||||||
field_three_center_time.%: src/beacon_field.py
|
field_three_center_time.%: src/beacon_field.py
|
||||||
$< --time $@ three-center
|
$< --time $@ three-center
|
||||||
|
@ -68,8 +79,8 @@ field_three_center_time_nomax.%: src/beacon_field.py
|
||||||
$< --time $@ three-center --max-rms 0
|
$< --time $@ three-center --max-rms 0
|
||||||
field_three_center_phase.%: src/beacon_field.py
|
field_three_center_phase.%: src/beacon_field.py
|
||||||
$< --phase $@ three-center
|
$< --phase $@ three-center
|
||||||
field_three_center_time_nomax.%: src/beacon_field.py
|
field_three_center_phase_nomax.%: src/beacon_field.py
|
||||||
$< --time $@ three-center --max-rms 0
|
$< --phase $@ three-center --max-rms 0
|
||||||
|
|
||||||
|
|
||||||
field_square: \
|
field_square: \
|
||||||
|
|
|
@ -255,6 +255,20 @@ if __name__ == "__main__":
|
||||||
|
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
|
|
||||||
|
if False: #specific formatting
|
||||||
|
from matplotlib import rcParams
|
||||||
|
#rcParams["text.usetex"] = True
|
||||||
|
rcParams["font.family"] = "serif"
|
||||||
|
rcParams["font.size"] = "12"
|
||||||
|
if True:# small
|
||||||
|
figsize = (6, 4)
|
||||||
|
rcParams["font.size"] = "14" # 15 at 6,4 looks fine
|
||||||
|
elif True: # large
|
||||||
|
figsize = (9, 6)
|
||||||
|
rcParams["grid.linestyle"] = 'dotted'
|
||||||
|
rcParams["figure.figsize"] = figsize
|
||||||
|
|
||||||
|
|
||||||
if args.fname == 'none':
|
if args.fname == 'none':
|
||||||
args.fname = None
|
args.fname = None
|
||||||
|
|
||||||
|
@ -347,8 +361,9 @@ if __name__ == "__main__":
|
||||||
kwargs = {}
|
kwargs = {}
|
||||||
mask = None
|
mask = None
|
||||||
if plot_phase:
|
if plot_phase:
|
||||||
color_label='$\\sqrt{ \\sum_{(i,j)} \\left(\\Delta\\varphi_{ij}(x) - \\Delta \\varphi_{ij}\\right)^2}$'
|
color_label='$\\sqrt{ \\sum_{(i,j)} \\left(\\Delta\\varphi_{ij}(x) - \\Delta \\varphi_{ij}\\right)^2}$ [rad]'
|
||||||
min_val = min(val)
|
if args.max_rms:
|
||||||
|
min_val = abs(min(min(val), args.max_rms))
|
||||||
mask = abs(val) > np.pi + min_val
|
mask = abs(val) > np.pi + min_val
|
||||||
else:
|
else:
|
||||||
color_label='$\\sqrt{ \\sum_{(i,j)} \\left(\Delta t_{ij}(x) - \\Delta t_{ij}\\right)^2}$ [ns]'
|
color_label='$\\sqrt{ \\sum_{(i,j)} \\left(\Delta t_{ij}(x) - \\Delta t_{ij}\\right)^2}$ [ns]'
|
||||||
|
@ -377,6 +392,9 @@ if __name__ == "__main__":
|
||||||
if isinstance(args.fname, str):
|
if isinstance(args.fname, str):
|
||||||
args.fname = [args.fname]
|
args.fname = [args.fname]
|
||||||
|
|
||||||
|
fig = plt.gcf()
|
||||||
|
fig.tight_layout()
|
||||||
|
|
||||||
for fname in args.fname:
|
for fname in args.fname:
|
||||||
plt.savefig(fname)
|
plt.savefig(fname)
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue