class_docstr: Actor which tests will report metrics to.
code: def __init__(self, expected_measurements_per_test: int):
      self.measurements = defaultdict(list)
      self.expected_measurements_per_test = (
          expected_measurements_per_test
      )
  
imports: from collections import defaultdict
  from dataclasses import dataclass
  from ray._private.test_utils import safe_write_to_results_json
  from ray.job_submission import JobSubmissionClient, JobStatus
  import argparse
  import asyncio
  import random
  import ray
  import statistics
  import subprocess
  import sys
label_desc: Use image node_id 1 to create a new MetricsActor object  with example: obj = MetricsActor(expected_measurements_per_test)