code: def __init__(
      self, params: ModelParams, name="CalamariGraph", **kwargs
  ):
      super().__init__(params, name=name, **kwargs)
      assert params.classes > 0, "non initialized number of classes"
  
      self.layer_instances = [l.create() for l in params.layers]
  
      self.reshape = ToInputDimsLayerParams(dims=3).create()
      self.logits = KL.Dense(params.classes, name="logits")
      self.softmax = KL.Softmax(name="softmax")
      self.temperature = (
          tf.constant(
              params.temperature, dtype=tf.float32, name="temperature"
          )
          if params.temperature > 0
          else None
      )
  
file_path: calamari/calamari_ocr/ocr/model/graph.py
imports: from functools import partial
  import tensorflow
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import ctc_ops
  from tfaip.model.graphbase import GraphBase
  from calamari_ocr.ocr.model.layers.concat import ConcatLayerParams
  from calamari_ocr.ocr.model.layers.toinputdims import ToInputDimsLayerParams
  from calamari_ocr.ocr.model.layers.transposedconv2d import TransposedConv2DLayerParams
  from calamari_ocr.ocr.model.params import ModelParams
label_desc: Use image node_id 1 to create a new CalamariGraph object from inherited base classes: GraphBase with example: obj = CalamariGraph(params, name)