class_docstr: Selects the right wrapper (based on the environment), runs, and saves the src.
docstr: Writes a table with the best result found so far.
docstr_tok: ["Writes","a","table","with","the","best","result","found","so","far","."]
code: def _write_table(self) -> None:
      """Writes a table with the best result found so far."""
      d = self._data[self._computer]
  
      versions = set()
      for task in TASKS:
          for version in d[task.id]["trajectory_walltime"].keys():
              versions.add(version)
  
      # For each version a column
      data = defaultdict(list)
      for task in TASKS:
          data["tasks"].append(task.name)
          data["n_trials"].append(str(task.n_trials))
          data["walltime"].append(str(task.walltime_limit))
          data["instances"].append(str(task.use_instances))
  
          for version in versions:
              not_found = False
              for seed in SEEDS:
                  if (
                      seed
                      not in d[task.id]["trajectory_walltime"][version]
                  ):
                      not_found = True
                      break
  
              if not_found:
                  data[f"{version} (cost / time)"].append("N/A")
                  continue
  
              values = d[task.id]["trajectory_walltime"][
                  version
              ].values()
              X, Y_array, Y_mean, Y_std = self._get_mean_std(values)
              data[f"{version} (cost / time)"].append(
                  f"{round(Y_mean[-1], 2)} +- {round(Y_std[-1], 2)} / {round(X[-1], 2)}"
              )
  
      # Now make a dataframe
      df = pd.DataFrame(data=data)
      df.to_csv("report/table.csv", index=False)
  
imports: from __future__ import annotations
  import sys
  import logging
  from typing import Any
  import numpy
  import json
  import socket
  from collections import defaultdict
  from pathlib import Path
  import pandas
  from src.tasks import TASKS
  from src.utils.exceptions import NotSupportedError
  from src.utils.styled_plot import plt
  from src.wrappers.v14 import Version14
  from src.wrappers.v20 import Version20
  from src.wrappers.wrapper import Wrapper
label_desc: Use image node_id 8 for calling the Benchmark obj's underlying member method code with example usage: obj._write_table() without return types