-
Notifications
You must be signed in to change notification settings - Fork 4
/
paths.py
67 lines (40 loc) · 2.23 KB
/
paths.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
import os
# root path of the project
ROOT_DIR = os.path.dirname(os.path.abspath(__file__))
# directory for all runnable tasks
# the task directory should not be changed, otherwise the task manager will crash
TASK_DIR = os.path.join(ROOT_DIR, 'backend', 'task')
# directory for all tasks' logs
LOG_DIR = os.path.join(ROOT_DIR, 'backend', 'logs')
# dir for all configs
CONFIGS_DIR = os.path.join(ROOT_DIR, 'configs')
# path of the config file for connection to postgresql
DATABASE_CONFIG_PATH = os.path.join(CONFIGS_DIR, 'database.ini')
# path of the config file for twitter api
TWITTER_API_CONFIG_PATH = os.path.join(CONFIGS_DIR, 'twitter.ini')
# path of the config file for logging in task manager
LOG_CONFIG_PATH = os.path.join(CONFIGS_DIR, 'logger-conf.json')
# dir for all cache
CACHE_DIR = os.path.join(ROOT_DIR, 'cache')
TWITTER_TEXT_CACHE = os.path.join(CACHE_DIR, 'twitter.cache.pickle')
MODELS_SAVE_PATH = os.path.join(ROOT_DIR, 'backend', 'models')
NLTK_MODEL_PATH = os.path.join(MODELS_SAVE_PATH, 'nltk_model.pickle')
TEXT_CNN_MODEL_PATH = os.path.join(MODELS_SAVE_PATH, 'text_cnn_classifier.ckpt')
GOOGLE_VOCAB_PATH = os.path.join(MODELS_SAVE_PATH, 'GoogleNews-vectors-negative300.bin')
IMAGE_CLASSIFIER_VGG_PATH = os.path.join(MODELS_SAVE_PATH, 'img_classifier_model.ckpt')
IMAGE_CLASSIFIER_RESNET_PATH = os.path.join(MODELS_SAVE_PATH, 'ResNet1.ckpt')
EVENT2MIND_MODEL_PATH = os.path.join(MODELS_SAVE_PATH, 'event2mind-2018.10.26.tar.gz')
DATA_PATH = os.path.join(ROOT_DIR, 'data')
TEST_DATA_PATH = os.path.join(DATA_PATH, 'test')
GRIB2_DATA_DIR = os.path.join(DATA_PATH, 'grib-data')
SOIL_MOIS_DATA_DIR = os.path.join(DATA_PATH, 'soil-mois-data')
US_SHAPE_PATH = os.path.join(DATA_PATH, 'US-continental', 'US_continental.shp')
USGS_DATA_DIR = os.path.join(DATA_PATH, 'usgs')
WIND_DATA_DIR = os.path.join(ROOT_DIR, 'backend', 'data')
GRIB2JSON_PATH = os.path.join('converter', 'bin', 'grib2json')
FIRE_DATA_DIR = os.path.join(DATA_PATH, 'fire-data')
TWEET_IMAGES_DIR = os.path.join(DATA_PATH, 'tweet_images')
BOUNDARY_PATH = os.path.join(DATA_PATH, 'boundaries')
IMAGE_TRAIN_PATH = os.path.join(DATA_PATH, 'image_dataset/train')
IMAGE_VAL_PATH = os.path.join(DATA_PATH, 'image_dataset/val')
PRISM_DATA_PATH = os.path.join(DATA_PATH, 'prism')