Python module
identity
Identity layer that passes through input unchanged.
Identity
class max.nn.identity.Identity
Identity layer that passes through input unchanged.
This layer is useful for skipping certain operations (like normalization) in specific architectures such as EAGLE speculative decoding, where the draft model receives already-normalized hidden states from the target model.
Example:
>>> from max.nn import Identity
>>> identity = Identity()
>>> # In graph construction:
>>> output = identity(input_tensor) # output == input_tensorWas this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!