| # Copyright 2017 The Chromium OS Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| """Module containing the constants to be reused throughout bad_cl_detector.""" |
| |
| import os |
| |
| # Constants for specifying the directories and folders |
| LOCAL_DIR = os.path.dirname(__file__) |
| ROOT_DIR = os.path.join(LOCAL_DIR, '..') |
| ROOT_DATA_FOLDER = 'data' |
| USAGE_TRAIN = 'training' |
| USAGE_PREDICT = 'prediction' |
| |
| # Input directory template |
| FEATURE_INPUT_TEMPLATE = '%s/%s/%s/raw_data' |
| # Output directory template |
| FEATURE_OUTPUT_TEMPLATE = '%s/%s/%s/feature' |
| |
| FEATURE_TYPE_STAGE = 'stage' |
| STAGE_TRAIN_FILE = 'stage_training_data.csv' |
| |
| FEATURE_TYPE_CL = 'cl' |
| CL_TRAIN_FILE = 'cl_training_data.csv' |
| |
| # other constants |
| INTERNAL = 'internal' |
| EXTERNAL = 'external' |
| CSV_SUFFIX = '.csv' |
| TRUE = 1 |
| FALSE = 0 |
| STATUS_FAIL = 'fail' |
| STATUS_PASS = 'pass' |
| STATUS_SKIP = 'skipped' |