code: def load_data_using_dataset_api(
      src_vocab, src_path, target_vocab, target_path, filter_func
  ):
      def _transform_line(vocabulary, line):
          words = line.strip().split()
          return numpy.array(
              [vocabulary.get(w, UNK) for w in words], numpy.int32
          )
  
      def _transform(example):
          source, target = example
          return (
              _transform_line(src_vocab, source),
              _transform_line(target_vocab, target),
          )
  
      return chainer.datasets.TransformDataset(
          chainer.datasets.TextDataset(
              [src_path, target_path],
              encoding="utf-8",
              filter_func=filter_func,
          ),
          _transform,
      )
  
imports: import argparse
  import datetime
  import io
  from nltk.translate import bleu_score
  import numpy
  import progressbar
  import six
  import chainer
  import chainer.functions
  import chainer.links
  from chainer import training
  from chainer.training import extensions
  import chainerx
label_desc: Use image node_id 6 for calling a global function with example usage: load_data_using_dataset_api(src_vocab, src_path, target_vocab, target_path, filter_func) and returns: chainer, numpy, _transform_line,  _transform_line