We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a16c4ec commit f5e67d4Copy full SHA for f5e67d4
varipeps/optimization/optimizer.py
@@ -755,6 +755,30 @@ def random_noise(a):
755
additional_input,
756
)
757
758
+ if working_value < best_value:
759
+ _autosave_wrapper(
760
+ autosave_func,
761
+ autosave_filename,
762
+ working_tensors,
763
+ working_unitcell,
764
+ working_value,
765
+ "best",
766
+ random_noise_retries,
767
+ max_trunc_error_list,
768
+ step_energies,
769
+ step_chi,
770
+ step_conv,
771
+ step_runtime,
772
+ spiral_indices,
773
+ additional_input,
774
+ )
775
+
776
777
+ best_value = working_value
778
+ best_tensors = working_tensors
779
+ best_unitcell = working_unitcell
780
+ best_run = random_noise_retries
781
782
if working_value < best_value:
783
best_value = working_value
784
best_tensors = working_tensors
0 commit comments