class_docstr: Base semiring class.
  
  Based on description in:
  
  * Semiring parsing :cite:`goodman1999semiring`
docstr: Generalized tensordot. Classes should override.
docstr_tok: ["Generalized","tensordot",".","Classes","should","override","."]
code: def matmul(cls, a, b):
      "Generalized tensordot. Classes should override."
      return matmul(cls, a, b)
  
imports: import torch
label_desc: Use image node_id 1 for calling the Semiring obj's underlying member method code with example usage: obj.matmul(cls, a, b) and returns: matmul