Skip to content

Commit

Permalink
Put datumaro in path in settings
Browse files Browse the repository at this point in the history
  • Loading branch information
zhiltsov-max committed Mar 26, 2020
1 parent 5030c5d commit 3701187
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
5 changes: 1 addition & 4 deletions cvat/apps/dataset_manager/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,16 @@
import os
import os.path as osp
import shutil
import sys
import tempfile

from django.utils import timezone
import django_rq

from cvat.settings.base import DATUMARO_PATH as _DATUMARO_REPO_PATH
from cvat.apps.engine.log import slogger
from cvat.apps.engine.models import Task
from .util import current_function_name, make_zip_archive

_CVAT_ROOT_DIR = __file__[:__file__.rfind(osp.join('cvat', ''))]
_DATUMARO_REPO_PATH = osp.join(_CVAT_ROOT_DIR, 'datumaro')
sys.path.append(_DATUMARO_REPO_PATH)
from datumaro.components.project import Project, Environment
import datumaro.components.extractor as datumaro
from .bindings import CvatImagesDirExtractor, CvatTaskExtractor
Expand Down
3 changes: 3 additions & 0 deletions cvat/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -401,3 +401,6 @@ def generate_ssh_keys():
DATA_UPLOAD_MAX_NUMBER_FIELDS = None # this django check disabled
LOCAL_LOAD_MAX_FILES_COUNT = 500
LOCAL_LOAD_MAX_FILES_SIZE = 512 * 1024 * 1024 # 512 MB

DATUMARO_PATH = os.path.join(BASE_DIR, 'datumaro')
sys.path.append(DATUMARO_PATH)

0 comments on commit 3701187

Please sign in to comment.