class_docstr: Simple fixed capacity shared memory queue of fixed size messages.
  Writing to a full queue fails, attempt to get from an empty queue blocks until data is
  available or the queue is closed.
class_docstr_tok: ["Simple","fixed","capacity","shared","memory","queue","of","fixed","size","messages",".","Writing","to","a","full","queue","fails",",","attempt","to","get","from","an","empty","queue","blocks","until","data","is","available","or","the","queue","is","closed","."]
code: def close(self):
      if self.is_closed:
          return
      with self.lock:
          self._read_meta()
          self.is_closed = True
          if not self.meta.is_closed:
              self.meta.is_closed = 1
              self._write_meta()
              # Notify only one waiting worker about closing the queue, the woken up worker
              # will notify the next one. Avoid notify_all at this point, due to possible
              # deadlock if one of the notified workers exited abruptly when waiting
              # on cv_not_empty without proper releasing of the underlying semaphore.
              self.cv_not_empty.notify()
  
imports: from typing import List, Optional
  import os
  import threading
  from nvidia.dali._multiproc import shared_mem
  from nvidia.dali._multiproc.messages import Structure, ShmMessageDesc
  from nvidia.dali._multiproc.shared_batch import _align_up
label_desc: Use image node_id 13 for calling the ShmQueue obj's underlying member method code with example usage: obj.close() without return types