MCPcopy Create free account
hub / github.com/Sygil-Dev/sygil-webui / normalization

Function normalization

ldm/modules/diffusionmodules/util.py:225–231  ·  view source on GitHub ↗

Make a standard normalization layer. :param channels: number of input channels. :return: an nn.Module for normalization.

(channels)

Source from the content-addressed store, hash-verified

223
224
225def normalization(channels):
226 """
227 Make a standard normalization layer.
228 :param channels: number of input channels.
229 :return: an nn.Module for normalization.
230 """
231 return GroupNorm32(32, channels)
232
233
234# PyTorch 1.7 has SiLU, but we support PyTorch 1.5.

Callers 7

__init__Method · 0.90
__init__Method · 0.90
__init__Method · 0.90
__init__Method · 0.90
__init__Method · 0.90
__init__Method · 0.90
__init__Method · 0.90

Calls 1

GroupNorm32Class · 0.85

Tested by

no test coverage detected