storeExperimentalInformations.py
def store_experiments_information(self, nb_instance, nb_model, filename1, filename2=None, filename3=None, 
            filename4=None, filename_multimodal=None, filename_all="", multimodal_filename="multimodal.csv"):
        """ 
        Compute the mean coverage, precision and f2 per model 
        Args: nb_instance: Number of instance for which we generate explanation for each model
              nb_model: Numerous of the black box model for which we generate explanation (first model employed = 0 , second model employed = 1, etc...)
        """
        os.makedirs(os.path.dirname(self.filename), exist_ok=True)
        os.makedirs(os.path.dirname(filename_all), exist_ok=True)

        self.pd_all_models_results1 = self.pd_all_models_results1.append(self.pd_results1)
        self.pd_results1.to_csv(self.filename + filename1, index=False)
        self.pd_all_models_results1.to_csv(filename_all + filename1, index=False)

        if filename2 is not None:
            self.pd_all_models_results2 = self.pd_all_models_results2.append(self.pd_results2)
            self.pd_results2.to_csv(self.filename + filename2, index=False)
            self.pd_all_models_results2.to_csv(filename_all + filename2, index=False)
        
        if filename3 is not None:
            self.pd_all_models_results3 = self.pd_all_models_results3.append(self.pd_results3)
            self.pd_results3.to_csv(self.filename + filename3, index=False)
            self.pd_all_models_results3.to_csv(filename_all + filename3, index=False)
        
        if filename4 is not None:
            self.pd_all_models_results4 = self.pd_all_models_results4.append(self.pd_results4)
            self.pd_results4.to_csv(self.filename + filename4, index=False)
            self.pd_all_models_results4.to_csv(filename_all + filename4, index=False)

        if filename_multimodal is not None:
            self.pd_all_models_multimodal = self.pd_all_models_multimodal.append(self.pd_multimodal)
            self.pd_multimodal.to_csv(self.filename + multimodal_filename, index=False)
            self.pd_all_models_multimodal.to_csv(filename_all + multimodal_filename, index=False)
 
        Compute the mean coverage, precision and f2 per model 
        Args: nb_instance: Number of instance for which we generate explanation for each model
              nb_model: Numerous of the black box model for which we generate explanation (first model employed = 0 , second model employed = 1, etc...)
        
Compute the mean coverage, precision and f2 per model
Args: nb_instance: Number of instance for which we generate explanation for each model
nb_model: Numerous of the black box model for which we generate explanation (first model employed = 0 , second model employed = 1, etc...)
Compute the mean coverage precision and f2 per model Args : nb_instance : Number of instance for which we generate explanation for each model nb_model : Numerous of the black box model for which we generate explanation ( first model employed = 0 second model employed = 1 etc ... )
def store_experiments_information(self, nb_instance, nb_model, filename1, filename2=None, filename3=None, 
            filename4=None, filename_multimodal=None, filename_all="", multimodal_filename="multimodal.csv"):
        os.makedirs(os.path.dirname(self.filename), exist_ok=True)
        os.makedirs(os.path.dirname(filename_all), exist_ok=True)
        self.pd_all_models_results1 = self.pd_all_models_results1.append(self.pd_results1)
        self.pd_results1.to_csv(self.filename + filename1, index=False)
        self.pd_all_models_results1.to_csv(filename_all + filename1, index=False)
        if filename2 is not None:
            self.pd_all_models_results2 = self.pd_all_models_results2.append(self.pd_results2)
            self.pd_results2.to_csv(self.filename + filename2, index=False)
            self.pd_all_models_results2.to_csv(filename_all + filename2, index=False)
        if filename3 is not None:
            self.pd_all_models_results3 = self.pd_all_models_results3.append(self.pd_results3)
            self.pd_results3.to_csv(self.filename + filename3, index=False)
            self.pd_all_models_results3.to_csv(filename_all + filename3, index=False)
        if filename4 is not None:
            self.pd_all_models_results4 = self.pd_all_models_results4.append(self.pd_results4)
            self.pd_results4.to_csv(self.filename + filename4, index=False)
            self.pd_all_models_results4.to_csv(filename_all + filename4, index=False)
        if filename_multimodal is not None:
            self.pd_all_models_multimodal = self.pd_all_models_multimodal.append(self.pd_multimodal)
            self.pd_multimodal.to_csv(self.filename + multimodal_filename, index=False)
            self.pd_all_models_multimodal.to_csv(filename_all + multimodal_filename, index=False)
def store_experiments_information ( self , nb_instance , nb_model , filename1 , filename2 = None , filename3 = None , filename4 = None , filename_multimodal = None , filename_all = "" , multimodal_filename = "multimodal.csv" ) : os . makedirs ( os . path . dirname ( self . filename ) , exist_ok = True ) os . makedirs ( os . path . dirname ( filename_all ) , exist_ok = True ) self . pd_all_models_results1 = self . pd_all_models_results1 . append ( self . pd_results1 ) self . pd_results1 . to_csv ( self . filename + filename1 , index = False ) self . pd_all_models_results1 . to_csv ( filename_all + filename1 , index = False ) if filename2 is not None : self . pd_all_models_results2 = self . pd_all_models_results2 . append ( self . pd_results2 ) self . pd_results2 . to_csv ( self . filename + filename2 , index = False ) self . pd_all_models_results2 . to_csv ( filename_all + filename2 , index = False ) if filename3 is not None : self . pd_all_models_results3 = self . pd_all_models_results3 . append ( self . pd_results3 ) self . pd_results3 . to_csv ( self . filename + filename3 , index = False ) self . pd_all_models_results3 . to_csv ( filename_all + filename3 , index = False ) if filename4 is not None : self . pd_all_models_results4 = self . pd_all_models_results4 . append ( self . pd_results4 ) self . pd_results4 . to_csv ( self . filename + filename4 , index = False ) self . pd_all_models_results4 . to_csv ( filename_all + filename4 , index = False ) if filename_multimodal is not None : self . pd_all_models_multimodal = self . pd_all_models_multimodal . append ( self . pd_multimodal ) self . pd_multimodal . to_csv ( self . filename + multimodal_filename , index = False ) self . pd_all_models_multimodal . to_csv ( filename_all + multimodal_filename , index = False )
Compute the mean coverage, precision and f2 per model
Args: nb_instance: Number of instance for which we generate explanation for each model
nb_model: Numerous of the black box model for which we generate explanation (first model employed = 0 , second model employed = 1, etc...)
Compute the mean coverage precision and f2 per model Args : nb_instance : Number of instance for which we generate explanation for each model nb_model : Numerous of the black box model for which we generate explanation ( first model employed = 0 second model employed = 1 etc ... )
""" 
        Compute the mean coverage, precision and f2 per model 
        Args: nb_instance: Number of instance for which we generate explanation for each model
              nb_model: Numerous of the black box model for which we generate explanation (first model employed = 0 , second model employed = 1, etc...)
        """
self
nb_instance
nb_model
filename1
filename2
filename3
filename4
filename_multimodal
filename_all
multimodal_filename