code: def get_signature_size(msg):
      
      if isinstance(msg, (TxinGen, TxinToScript, TxinToScriptHash)):
          return 0
      elif isinstance(msg, TxinToKey):
          return len(msg.key_offsets)
      else:
          raise ValueError('Unknown tx in')
docs: Returns a signature size for the input
      :param msg:
      :return: