class_docstr: Base class for image classification problems.
class_docstr_tok: ["Base","class","for","image","classification","problems","."]
code: def hparams(self, defaults, unused_model_hparams):
      p = defaults
      p.modality = {
          "inputs": modalities.ModalityType.IMAGE,
          "targets": modalities.ModalityType.CLASS_LABEL,
      }
      p.vocab_size = {"inputs": 256, "targets": self.num_classes}
      p.batch_size_multiplier = 4 if self.is_small else 256
      p.loss_multiplier = 3.0 if self.is_small else 1.0
      if self._was_reversed:
          p.loss_multiplier = 1.0
      p.input_space_id = problem.SpaceID.IMAGE
      p.target_space_id = problem.SpaceID.IMAGE_LABEL
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import io
  import os
  import numpy
  from tensor2tensor.data_generators import generator_utils
  from tensor2tensor.data_generators import problem
  from tensor2tensor.data_generators import text_encoder
  from tensor2tensor.layers import common_layers
  from tensor2tensor.layers import modalities
  from tensor2tensor.utils import contrib
  from tensor2tensor.utils import metrics
  import tensorflow.compat.v1
label_desc: Use image node_id 9 for calling the Image2ClassProblem obj's underlying member method code with example usage: obj.hparams(defaults, unused_model_hparams) without return types