code: def test_remove_special_queued_experiments(
      tmp_dir, scm, dvc, exp_stage
  ):
      dvc.experiments.run(
          exp_stage.addressing,
          params=["foo=1"],
          queue=True,
          name="queue1",
      )
      dvc.experiments.run(
          exp_stage.addressing,
          params=["foo=2"],
          queue=True,
          name="queue2",
      )
      dvc.experiments.run(
          exp_stage.addressing,
          params=["foo=3"],
          queue=True,
          name="queue3",
      )
      queue_revs = {
          entry.name: entry.stash_rev
          for entry in dvc.experiments.celery_queue.iter_queued()
      }
      assert len(queue_revs) == 3
  
      results = dvc.experiments.run(
          exp_stage.addressing, params=["foo=4"]
      )
      ref_info1 = first(exp_refs_by_rev(scm, first(results)))
      results = dvc.experiments.run(
          exp_stage.addressing, params=["foo=5"]
      )
      ref_info2 = first(exp_refs_by_rev(scm, first(results)))
  
      assert scm.get_ref(str(ref_info1)) is not None
      assert scm.get_ref(str(ref_info2)) is not None
  
      rev2 = queue_revs["queue2"]
      assert set(
          dvc.experiments.remove(["queue1", rev2[:5], str(ref_info1)])
      ) == {
          "queue1",
          rev2[:5],
          str(ref_info1),
      }
      assert len(list(dvc.experiments.celery_queue.iter_queued())) == 1
      assert scm.get_ref(str(ref_info1)) is None
      assert scm.get_ref(str(ref_info2)) is not None
  
file_path: dvc/tests/func/experiments/test_remove.py
imports: import pytest
  from funcy import first
  from dvc.exceptions import InvalidArgumentError
  from dvc.repo.experiments.exceptions import UnresolvedExpNamesError
  from dvc.repo.experiments.utils import exp_refs_by_rev
label_desc: Use image node_id 3 for calling a global function with example usage: test_remove_special_queued_experiments(tmp_dir, scm, dvc, exp_stage) without return types