code: def write_txt(w_path: str, val: str):
      """
      Write a text file from the string input.
  
      Args:
          w_path (str):
              Target path for saving a file
          val (str):
              String variable to be written
      """
      with open(w_path, "w") as output:
          output.write(val + "\n")
  
imports: import copy
  import csv
  import json
  import os
  from collections import OrderedDict
  from datetime import datetime
  from typing import Dict, List, Tuple
  import numpy
  from nemo.collections.asr.metrics.der import concat_perm_word_error_rate
  from nemo.collections.asr.metrics.wer import word_error_rate
  from nemo.collections.asr.models import ClusteringDiarizer
  from nemo.collections.asr.parts.utils.speaker_utils import audio_rttm_map, get_uniqname_from_filepath, labels_to_rttmfile, rttm_to_labels, write_rttm2manifest
  from nemo.utils import logging
label_desc: Use image node_id 2 for calling a global function with example usage: write_txt(w_path, val) without return types