class_docstr: ResNet block.
class_docstr_tok: ["ResNet","block","."]
code: def __call__(
      self,
      x,
  ):
      residual = x
      y = self.conv(self.filters, (3, 3), self.strides)(x)
      y = self.norm()(y)
      y = self.act(y)
      y = self.conv(self.filters, (3, 3))(y)
      y = self.norm(scale_init=nn.initializers.zeros_init())(y)
  
      if residual.shape != y.shape:
          residual = self.conv(
              self.filters, (1, 1), self.strides, name="conv_proj"
          )(residual)
          residual = self.norm(name="norm_proj")(residual)
  
      return self.act(residual + y)
  
file_path: flax/examples/imagenet/models.py
imports: from functools import partial
  from typing import Any, Callable, Sequence, Tuple
  from flax import linen
  import jax.numpy
label_desc: Use image node_id 1 for calling the ResNetBlock obj's underlying member method code with example usage: obj.__call__(x) and returns: self