code: def model_wo_softmax(model: Model) -> Model:
      """Creates a new model w/o the final softmax activation."""
      return kmodels.Model(
          inputs=model.inputs,
          outputs=pre_output_tensors(
              model.outputs, activation="softmax"
          ),
          name=model.name,
      )
  
imports: from __future__ import annotations
  import inspect
  import warnings
  from abc import ABCMeta, abstractmethod
  from typing import Any, Callable
  import numpy
  import tensorflow.keras.backend
  import tensorflow.keras.layers
  import tensorflow.keras.models
  import innvestigate.backend
  import innvestigate.backend.checks
  import innvestigate.layers
  from innvestigate.backend.types import Layer, LayerCheck, Model, NodeDict, OptionalList, ReverseTensorDict, Tensor
label_desc: Use image node_id 10 for calling a global function with example usage: model_wo_softmax(model) and returns: kmodels