MCPcopy Create free account
hub / github.com/TencentARC/InstantMesh / validation_step

Method validation_step

src/model_mesh.py:294–301  ·  view source on GitHub ↗
(self, batch, batch_idx)

Source from the content-addressed store, hash-verified

292
293 @torch.no_grad()
294 def validation_step(self, batch, batch_idx):
295 lrm_generator_input = self.prepare_validation_batch_data(batch)
296
297 render_out = self.forward(lrm_generator_input)
298 render_images = render_out['img']
299 render_images = rearrange(render_images, 'b n c h w -> b c h (n w)')
300
301 self.validation_step_outputs.append(render_images)
302
303 def on_validation_epoch_end(self):
304 images = torch.cat(self.validation_step_outputs, dim=-1)

Callers

nothing calls this directly

Calls 2

forwardMethod · 0.95

Tested by

no test coverage detected