forked from enviPath/enviPy
Model Building UI Flag (#39)
Fixes #8 Flag only disables UI Elements Co-authored-by: Tim Lorsbach <tim@lorsba.ch> Reviewed-on: enviPath/enviPy#39
This commit is contained in:
@ -260,6 +260,8 @@ CELERY_RESULT_BACKEND = 'redis://localhost:6379/1'
|
||||
CELERY_ACCEPT_CONTENT = ['json']
|
||||
CELERY_TASK_SERIALIZER = 'json'
|
||||
|
||||
MODEL_BUILDING_ENABLED = os.environ.get('MODEL_BUILDING_ENABLED', 'False') == 'True'
|
||||
|
||||
DEFAULT_RF_MODEL_PARAMS = {
|
||||
'base_clf': RandomForestClassifier(
|
||||
n_estimators=100,
|
||||
@ -312,3 +314,12 @@ if SENTRY_ENABLED:
|
||||
# see https://docs.sentry.io/platforms/python/data-management/data-collected/ for more info
|
||||
send_default_pii=True,
|
||||
)
|
||||
|
||||
# compile into digestible flags
|
||||
FLAGS = {
|
||||
'MODEL_BUILDING': MODEL_BUILDING_ENABLED,
|
||||
'CELERY': FLAG_CELERY_PRESENT,
|
||||
'PLUGINS': PLUGINS_ENABLED,
|
||||
'SENTRY': SENTRY_ENABLED,
|
||||
'ENVIFORMER': ENVIFORMER_PRESENT,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user