class_docstr: Decoder for :class:`~ffcv.fields.RGBImageField` that performs a center crop operation.
  
  It supports both variable and constant resolution datasets.
  
  Differently from the original CenterCropRGBImageDecoder from FFCV,
  this operates like torchvision CenterCrop.
code: def declare_state_and_memory(
      self, previous_state: State
  ) -> Tuple[State, AllocationQuery]:
      widths = self.metadata["width"]
      heights = self.metadata["height"]
      # We convert to uint64 to avoid overflows
      self.max_width = np.uint64(widths.max())
      self.max_height = np.uint64(heights.max())
      output_shape = (self.output_size[0], self.output_size[1], 3)
      my_dtype = np.dtype("<u1")
  
      return (
          replace(
              previous_state,
              jit_mode=True,
              shape=output_shape,
              dtype=my_dtype,
          ),
          (
              AllocationQuery(output_shape, my_dtype),
              AllocationQuery(
                  (self.max_height * self.max_width * np.uint64(3),),
                  my_dtype,
              ),
          ),
      )
  
file_path: avalanche/avalanche/benchmarks/utils/ffcv_support/center_crop.py
imports: from typing import Callable, Tuple
  from ffcv.fields.decoders import SimpleRGBImageDecoder
  from ffcv.pipeline.state import State
  from ffcv.pipeline.allocation_query import AllocationQuery
  import numpy
  from dataclasses import replace
  from ffcv.fields.rgb_image import IMAGE_MODES
  from ffcv.pipeline.compiler import Compiler
  from ffcv.libffcv import imdecode
label_desc: Use image node_id 2 for calling the CenterCropRGBImageDecoderTVAlike obj's underlying member method code with example usage: obj.declare_state_and_memory(previous_state) and returns: replace,  AllocationQuery,  AllocationQuery