nodes: 0, module; 1, function_definition; 2, function_name:get_trg_ids; 3, parameters; 4, type; 5, block; 6, identifier:self; 7, typed_parameter; 8, attribute; 9, expression_statement; 10, comment:# TODO: When MXNet adds support for set operations, we can migrate to avoid conversions to/from NumPy.; 11, expression_statement; 12, expression_statement; 13, return_statement; 14, identifier:src_ids; 15, type; 16, identifier:np; 17, identifier:ndarray; 18, comment:"""
          Lookup possible target ids for input sequence of source ids.
  
          :param src_ids: Sequence(s) of source ids (any shape).
          :return: Possible target ids for source (unique sorted, always includes special symbols).
          """; 19, assignment; 20, assignment; 21, identifier:trg_ids; 22, attribute; 23, identifier:unique_src_ids; 24, call; 25, identifier:trg_ids; 26, call; 27, identifier:np; 28, identifier:ndarray; 29, attribute; 30, argument_list; 31, attribute; 32, argument_list; 33, attribute; 34, identifier:unique; 35, identifier:src_ids; 36, attribute; 37, identifier:union1d; 38, attribute; 39, call; 40, attribute; 41, identifier:arraysetops; 42, attribute; 43, identifier:arraysetops; 44, identifier:self; 45, identifier:always_allow; 46, attribute; 47, argument_list; 48, identifier:np; 49, identifier:lib; 50, identifier:np; 51, identifier:lib; 52, subscript; 53, identifier:reshape; 54, unary_operator; 55, attribute; 56, identifier:unique_src_ids; 57, slice; 58, integer:1; 59, identifier:self; 60, identifier:lex
code: def get_trg_ids(self, src_ids: np.ndarray) -> np.ndarray:
          """
          Lookup possible target ids for input sequence of source ids.
  
          :param src_ids: Sequence(s) of source ids (any shape).
          :return: Possible target ids for source (unique sorted, always includes special symbols).
          """
          # TODO: When MXNet adds support for set operations, we can migrate to avoid conversions to/from NumPy.
          unique_src_ids = np.lib.arraysetops.unique(src_ids)
          trg_ids = np.lib.arraysetops.union1d(self.always_allow, self.lex[unique_src_ids, :].reshape(-1))
          return trg_ids