code: def check_rule(tensor_name, rule):
      if "Adam" in tensor_name or "adam" in tensor_name:
          return False
      assert isinstance(rule, str) and rule
      r_size = len(rule.split(" "))
      t = tensor_name.split(".")
      if len(t) < r_size:
          return False
      return rule == " ".join(t[-r_size:])
  
file_path: lightseq/examples/inference/python/export/fairseq/native_fs_moe_transformer_export.py
imports: import os
  import torch
  import argparse
  import numpy
  from collections import OrderedDict
  import lightseq.inference
  from proto.moe_pb2 import Moe
  from lightseq.training.ops.pytorch.export import gather_token_embedding, export_ls_config
  from lightseq.training.ops.pytorch.util import get_pos_embedding
label_desc: Use image node_id 2 for calling a global function with example usage: check_rule(tensor_name, rule) and returns: unknown, False, False