MCPcopy
hub / github.com/SizheAn/PanoHead / sample_mixed

Method sample_mixed

training/triplane.py:148–152  ·  view source on GitHub ↗
(self, coordinates, directions, ws, truncation_psi=1, truncation_cutoff=None, update_emas=False, **synthesis_kwargs)

Source from the content-addressed store, hash-verified

146 return self.renderer.run_model(planes, self.decoder, coordinates, directions, self.rendering_kwargs)
147
148 def sample_mixed(self, coordinates, directions, ws, truncation_psi=1, truncation_cutoff=None, update_emas=False, **synthesis_kwargs):
149 # Same as sample, but expects latent vectors 'ws' instead of Gaussian noise 'z'
150 planes = self.backbone.synthesis(ws, update_emas = update_emas, **synthesis_kwargs)
151 planes = planes.view(len(planes), 3, 32 * self.rendering_kwargs['triplane_depth'], planes.shape[-2], planes.shape[-1])
152 return self.renderer.run_model(planes, self.decoder, coordinates, directions, self.rendering_kwargs)
153
154 def forward(self, z, c, truncation_psi=1, truncation_cutoff=None, neural_rendering_resolution=None, update_emas=False, cache_backbone=False, use_cached_backbone=False, **synthesis_kwargs):
155 # Render a batch of generated images.

Callers 7

gen_interp_videoFunction · 0.80
gen_interp_videoFunction · 0.80
gen_interp_videoFunction · 0.80
gen_interp_videoFunction · 0.80
run_projectionFunction · 0.80
accumulate_gradientsMethod · 0.80
sample_cross_sectionFunction · 0.80

Calls 2

synthesisMethod · 0.80
run_modelMethod · 0.80

Tested by

no test coverage detected