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

Function expand_dims

guided_diffusion/dpm_solver.py:1248–1257  ·  view source on GitHub ↗

Expand the tensor `v` to the dim `dims`. Args: `v`: a PyTorch tensor with shape [N]. `dim`: a `int`. Returns: a PyTorch tensor with shape [N, 1, 1, ..., 1] and the total dimension is `dims`.

(v, dims)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 2

add_noiseMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected