MCPcopy Index your code
hub / github.com/ImprintLab/MedSegDiff / _extract_into_tensor

Function _extract_into_tensor

guided_diffusion/gaussian_diffusion.py:1126–1138  ·  view source on GitHub ↗

Extract values from a 1-D numpy array for a batch of indices. :param arr: the 1-D numpy array. :param timesteps: a tensor of indices into the array to extract. :param broadcast_shape: a larger shape of K dimensions with the batch dimension equal to the le

(arr, timesteps, broadcast_shape)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 10

q_mean_varianceMethod · 0.85
q_sampleMethod · 0.85
p_mean_varianceMethod · 0.85
condition_scoreMethod · 0.85
ddim_sampleMethod · 0.85
ddim_reverse_sampleMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected