code: def trylock(fd):
      try:
          fcntl.flock(fd, fcntl.LOCK_EX | fcntl.LOCK_NB)
          return True
      except Exception:  # pylint: disable=broad-except
          return False
  
file_path: tensorflow/tensorflow/tools/test/upload_test_benchmarks.py
imports: import argparse
  import datetime
  import fcntl
  import json
  import os
  import shutil
  from google.cloud import datastore
label_desc: Use image node_id 6 for calling a global function with example usage: trylock(fd) and returns: True, False