class_docstr: The result of flops profiling. Tuple of (flops, params).
  
  It has a :meth:`freeze` that mimics the behavior of :class:`MutableExpression`,
  and returns a frozen :class:`FlopsResult` object when a sample is provided.
class_docstr_tok: ["The","result","of","flops","profiling",".","Tuple","of","(","flops",",","params",")",".","It","has","a",":","meth",":","`","freeze","`","that","mimics","the","behavior","of",":","class",":","`","MutableExpression","`",",","and","returns","a","frozen",":","class",":","`","FlopsResult","`","object","when","a","sample","is","provided","."]
code: def __add__(self, other):
      if isinstance(other, FlopsResult):
          return FlopsResult(
              self.flops + other.flops, self.params + other.params
          )
      elif isinstance(other, (int, float)):
          return FlopsResult(self.flops + other, self.params)
      else:
          raise TypeError(
              f"Unsupported operand type(s) for +: '{type(self)}' and '{type(other)}'"
          )
  
imports: from __future__ import annotations
  import logging
  from dataclasses import dataclass, fields
  from functools import partial, reduce
  from typing import Any, NamedTuple, Callable, cast
  from torch import nn
  import nni.nas.nn.pytorch
  from nni.mutable import Sample, Mutable, MutableExpression
  from nni.nas.nn.pytorch import ModelSpace
  from nni.nas.profiler import Profiler, ExpressionProfiler
  from .utils import MutableShape, ShapeTensor, submodule_input_output_shapes, standardize_arguments, argument_in_spec, concat_name
  from .utils._attrs import tuple_n_t, _getattr
label_desc: Use image node_id 1 for calling the FlopsResult obj's underlying member method code with example usage: obj.__add__(other) and returns: FlopsResult, FlopsResult