Commit 6438ed5 1 parent f86ffc8 commit 6438ed5 Copy full SHA for 6438ed5
File tree 2 files changed +9
-4
lines changed
2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change 550
550
"name" : " stderr" ,
551
551
"output_type" : " stream" ,
552
552
"text" : [
553
- " /Users/laurent/dev/libraries/at/pyat/at/latticetools/response_matrix.py:579 : AtWarning: No new excluded value\n " ,
553
+ " /Users/laurent/dev/libraries/at/pyat/at/latticetools/response_matrix.py:584 : AtWarning: No new excluded value\n " ,
554
554
" warnings.warn(AtWarning(\" No new excluded value\" ), stacklevel=1)\n "
555
555
]
556
556
}
591
591
"name" : " stderr" ,
592
592
"output_type" : " stream" ,
593
593
"text" : [
594
- " /Users/laurent/dev/libraries/at/pyat/at/latticetools/response_matrix.py:579 : AtWarning: No new excluded value\n " ,
594
+ " /Users/laurent/dev/libraries/at/pyat/at/latticetools/response_matrix.py:584 : AtWarning: No new excluded value\n " ,
595
595
" warnings.warn(AtWarning(\" No new excluded value\" ), stacklevel=1)\n "
596
596
]
597
597
}
Original file line number Diff line number Diff line change @@ -466,8 +466,13 @@ def correct(
466
466
if apply :
467
467
self .variables .get (ring = ring , initial = True )
468
468
sumcorr = np .array ([0.0 ])
469
- for _ in range (niter ):
469
+ for it in range (niter ):
470
470
obs .evaluate (ring , ** self .eval_args )
471
+ err = obs .flat_deviations
472
+ if np .any (np .isnan (err )):
473
+ raise AtError (
474
+ f"Step { it + 1 } : Invalid observables, cannot compute correction"
475
+ )
471
476
corr = self .get_correction (obs .flat_deviations , nvals = nvals )
472
477
sumcorr = sumcorr + corr # non-broadcastable sumcorr
473
478
if apply :
@@ -787,7 +792,7 @@ def set_norm():
787
792
cavrefs ,
788
793
"Frequency" ,
789
794
name = "RF frequency" ,
790
- delta = cavdelta if cavdelta else 4 .0 * cavd ,
795
+ delta = cavdelta if cavdelta else 2 .0 * cavd ,
791
796
)
792
797
variables .append (cavvar )
793
798
You can’t perform that action at this time.
0 commit comments