@@ -559,21 +559,21 @@ def reconstruct_surfaces(
559559 smoothness_history .append ((alpha * smoothness_loss_per_heliostat ).mean ().detach ().cpu ().item ())
560560 ideal_history .append ((beta * ideal_surface_loss_per_heliostat ).mean ().detach ().cpu ().item ())
561561 energy_history .append (energy_constraint .mean ().detach ().cpu ().item ())
562- if epoch % 250 == 0 :
563- fig , axes = plt .subplots (nrows = cropped_flux_distributions .shape [0 ], ncols = 2 , figsize = (6 , 3 * cropped_flux_distributions .shape [0 ]))
562+ # if epoch % 250 == 0:
563+ # fig, axes = plt.subplots(nrows=cropped_flux_distributions.shape[0], ncols=2, figsize=(6, 3*cropped_flux_distributions.shape[0]))
564564
565- for i in range (cropped_flux_distributions .shape [0 ]):
566- # Compute min/max across the pair for shared color scale
567- im0 = axes [i , 0 ].imshow (cropped_flux_distributions [i ].detach ().cpu (), cmap = 'inferno' ,) #vmin=vmin, vmax=vmax)
568- axes [i , 0 ].set_title (f"Predicted { cropped_flux_distributions [i ].detach ().cpu ().sum ()} " )
569- axes [i , 0 ].axis ('off' )
565+ # for i in range(cropped_flux_distributions.shape[0]):
566+ # # Compute min/max across the pair for shared color scale
567+ # im0 = axes[i, 0].imshow(cropped_flux_distributions[i].detach().cpu(), cmap='inferno',) #vmin=vmin, vmax=vmax)
568+ # axes[i, 0].set_title(f"Predicted {cropped_flux_distributions[i].detach().cpu().sum()}")
569+ # axes[i, 0].axis('off')
570570
571- im1 = axes [i , 1 ].imshow (measured_flux_distributions [i ].detach ().cpu (), cmap = 'inferno' ,) # vmin=vmin, vmax=vmax)
572- axes [i , 1 ].set_title (f"Ground Truth { i } " )
573- axes [i , 1 ].axis ('off' )
571+ # im1 = axes[i, 1].imshow(measured_flux_distributions[i].detach().cpu(), cmap='inferno',) # vmin=vmin, vmax=vmax)
572+ # axes[i, 1].set_title(f"Ground Truth {i}")
573+ # axes[i, 1].axis('off')
574574
575- plt .tight_layout ()
576- plt .savefig (f"epoch_{ epoch } " )
575+ # plt.tight_layout()
576+ # plt.savefig(f"epoch_{epoch}")
577577 # Early stopping when loss did not improve for a predefined number of epochs.
578578 stop = early_stopper .step (loss )
579579
0 commit comments