code: def caching_exists_in_file(self, sql_query, graph_type):
      self.create_dir("data_storage")
      self.create_dir("data_storage/{}".format(graph_type))
  
      try:
          dictionary_csv = pd.read_csv(
              "./data_storage/filtered_df/dictionary_bkp.csv"
          )
          random_id = dictionary_csv[
              (dictionary_csv["sql"] == sql_query)
              & (dictionary_csv["type"] == graph_type)
              & (dictionary_csv["instance_id"] == self.instance_id)
          ]
  
          random_id.drop_duplicates(["sql"], keep="last", inplace=True)
          if not random_id.empty:
              result = random_id["random_id"].iloc[0]
              dff = pd.read_csv(
                  "./data_storage/{}/{}.csv".format(graph_type, result)
              )
              # print("{}  {}  {}".format(graph_type, "file exists", result))
              return True, True, dff
          return False, True, None
  
      except Exception as e:
          return False, False, None
  
imports: from imports import *
  from plotly_graphs import *
  from protodash import *
  from insights import *
  from plotly_css import *
  import pandasql
  import string
  import random
  import os
  from apps import global_explanation, local_explanation, distribution, feature_interaction, cohort
  from app import app
  from what_if import *
  from calculate_shap import *
  from analytics import Analytics
  from cohort_analysis import *
label_desc: Use image node_id 5 for calling the dashboard obj's underlying member method code with example usage: obj.caching_exists_in_file(sql_query, graph_type) and returns: False,  True,  None, True,  True,  dff, False,  False,  None