code: def nt_str(s):
      """Strip string to first null
  
      Parameters
      ----------
      s : bytes
  
      Returns
      -------
      sdash : str
         s stripped to first occurrence of null (0)
      """
      zero_pos = s.find(b"\x00")
      if zero_pos == -1:
          return s
      return s[:zero_pos].decode("latin-1")
  
file_path: nibabel/nibabel/nicom/csareader.py
imports: import numpy
  from .structreader import Unpacker
  from .utils import find_private_section
label_desc: Use image node_id 13 for calling a global function with example usage: nt_str(s) and returns: s, s