Ejemplo n.º 1
0
from utils.log_update_handler import DBLogUpdateHandler
from utils.log_utils import trimLog, collectLogData, valid_interval
from utils.log_utils import DEFAULT_INTERVAL as default_interval

parser = argparse.ArgumentParser(description="Run the benchmark remotely")

parser.add_argument(
    "--android_dir",
    default="/data/local/tmp/",
    help="The directory in the android device all files are pushed to.")
parser.add_argument(
    "--app_id",
    help="The app id you use to upload/download your file for everstore "
    "and access the job queue")
parser.add_argument("--claimer_id",
                    default=getMachineId(),
                    type=claimer_id_type,
                    help="A unique claimer id to represent itself. "
                    "Must talk to Caffe2 team to set it up.")
parser.add_argument("--cooldown",
                    default=0,
                    type=float,
                    help="Specify the time interval between two test runs.")
parser.add_argument(
    "-d",
    "--devices",
    help="Specify the devices to run the benchmark, in a comma separated "
    "list. The value is the device or device_hash field of the meta info.")
parser.add_argument(
    "--job_queue",
    default="aibench_interactive",
Ejemplo n.º 2
0
from reboot_device import reboot as reboot_device
from utils.check_argparse import claimer_id_type
from utils.custom_logger import getLogger, setLoggerLevel
from utils.utilities import getFilename, getMachineId, setRunKilled
from utils.utilities import killed_flag as RUN_KILLED
from utils.watchdog import WatchDog


parser = argparse.ArgumentParser(description="Run the benchmark remotely")

parser.add_argument("--android_dir", default="/data/local/tmp/",
    help="The directory in the android device all files are pushed to.")
parser.add_argument("--app_id",
    help="The app id you use to upload/download your file for everstore "
    "and access the job queue")
parser.add_argument("--claimer_id", default=getMachineId(),
    type=claimer_id_type, help="A unique claimer id to represent itself. "
    "Must talk to Caffe2 team to set it up.")
parser.add_argument("--cooldown", default=0, type=float,
    help="Specify the time interval between two test runs.")
parser.add_argument("-d", "--devices",
    help="Specify the devices to run the benchmark, in a comma separated "
    "list. The value is the device or device_hash field of the meta info.")
parser.add_argument("--job_queue",
    default="aibench_interactive",
    help="Specify the db job queue that the benchmark is sent to")
parser.add_argument("--logger_level", default="info",
    choices=["info", "warning", "error"],
    help="Specify the logger level")
parser.add_argument("--model_cache", required=True,
    help="The local directory containing the cached models. It should not "