code: def _print_if_not_none(obj):
      """Print like a notebook: Show the repr if the object is not None.
  
      `_patch_compile` Uses this on the final expression in each cell.
  
      This way the outputs feel like notebooks.
  
      Args:
        obj: the object to print.
      """
      if obj is not None:
          print(repr(obj))
  
file_path: tensorflow/tensorflow/tools/docs/fenced_doctest_lib.py
imports: import ast
  import doctest
  import os
  import re
  import textwrap
  from typing import Any, Callable, Dict, Iterable, Optional
  import astor
  from tensorflow.tools.docs import tf_doctest_lib
label_desc: Use image node_id 2 for calling a global function with example usage: _print_if_not_none(obj) without return types