code: def three_experiments_branch_same_name_trials_benchmarks(
      three_experiments_branch_same_name_trials, orionstate, storage
  ):
      """Create three experiments, two of them with the same name but different versions and one
      with a child, and add trials including children trials.
  
      Add algorithm state for one experiment.
      Add benchmarks to database.
      """
      # Add benchmarks, copied from db_dashboard_full.pkl
      orionstate.database.write(
          "benchmarks",
          [
              {
                  "_id": 1,
                  "algorithms": ["gridsearch", "random"],
                  "name": "branin_baselines_webapi",
                  "targets": [
                      {
                          "assess": {
                              "AverageResult": {"repetitions": 10}
                          },
                          "task": {"Branin": {"max_trials": 50}},
                      }
                  ],
              },
              {
                  "_id": 2,
                  "algorithms": [
                      "gridsearch",
                      "random",
                      {"tpe": {"n_initial_points": 20}},
                  ],
                  "name": "all_algos_webapi",
                  "targets": [
                      {
                          "assess": {
                              "AverageResult": {"repetitions": 3}
                          },
                          "task": {
                              "Branin": {"max_trials": 10},
                              "EggHolder": {"dim": 4, "max_trials": 20},
                              "RosenBrock": {
                                  "dim": 3,
                                  "max_trials": 10,
                              },
                          },
                      }
                  ],
              },
              {
                  "_id": 3,
                  "algorithms": [
                      "random",
                      {"tpe": {"n_initial_points": 20}},
                  ],
                  "name": "all_assessments_webapi_2",
                  "targets": [
                      {
                          "assess": {
                              "AverageRank": {"repetitions": 3},
                              "AverageResult": {"repetitions": 3},
                              "ParallelAssessment": {
                                  "executor": "joblib",
                                  "n_workers": (1, 2, 4, 8),
                                  "repetitions": 3,
                              },
                          },
                          "task": {
                              "Branin": {"max_trials": 10},
                              "RosenBrock": {
                                  "dim": 3,
                                  "max_trials": 10,
                              },
                          },
                      }
                  ],
              },
          ],
      )
  
imports: import copy
  import os
  import pickle
  import zlib
  from collections import Counter
  from tempfile import NamedTemporaryFile
  import pytest
  import yaml
  import orion.core.cli
  import orion.core.io.experiment_builder
  import orion.core.utils.backward
  from orion.core.worker.trial import Trial
  from orion.storage.backup import _get_exp_key, dump_database, get_experiment_parent_links, get_experiment_root_links, get_trial_parent_links
label_desc: Use image node_id 28 for calling a global function with example usage: three_experiments_branch_same_name_trials_benchmarks(three_experiments_branch_same_name_trials, orionstate, storage) without return types