class_docstr: Class for evaluating the performance of mapping W
class_docstr_tok: ["Class","for","evaluating","the","performance","of","mapping","W"]
docstr: Runs the whole CSLS metrics
  Arguments:
      sess(tf.session): Tensorflow Session
      batch_size(int): Batch Size
docstr_tok: ["Runs","the","whole","CSLS","metrics","Arguments",":","sess","(","tf.session",")",":","Tensorflow","Session","batch_size","(","int",")",":","Batch","Size"]
code: def run_csls_metrics(self, sess, batch_size=512):
      """
      Runs the whole CSLS metrics
      Arguments:
          sess(tf.session): Tensorflow Session
          batch_size(int): Batch Size
      """
      top_matches = []
      score = self.calc_csls_score(sess)
      avg1, avg2 = self.calc_avg_dist(sess)
      csls_scores = 2 * score - (
          avg1[self.src_ind][:, None] + avg2[None, :]
      )
      # Calculate top matches
      for i in range(0, len(self.src_ind), batch_size):
          scores = [
              csls_scores[x]
              for x in range(i, min(i + batch_size, len(self.src_ind)))
          ]
          top_matches_val = sess.run(
              self.csls_subgraphs["Top100"],
              feed_dict={self.score_ph: scores},
          )[1]
          top_matches.append(top_matches_val)
      top_matches = np.concatenate(top_matches)
      print("Accuracy using CSLS is")
      self.calc_accuracy(top_matches)
      self.calc_csls(sess)
  
file_path: nlp-architect/examples/crosslingembs/evaluate.py
imports: from __future__ import print_function, division
  import numpy
  import tensorflow
  from nlp_architect.data.fasttext_emb import get_eval_data
label_desc: Use image node_id 11 for calling the Evaluate obj's underlying member method code with example usage: obj.run_csls_metrics(sess, batch_size) without return types