Example #1
0
    def init_essential_files_and_directories(self):
        IS_RELATIVE = lambda d: not d.startswith('/')

        if len([True for item in [self.base_work_dir, self.input] if IS_RELATIVE(item)]):
            raise ConfigError, 'All paths should be absolute (starting with a "/").'

        if not os.path.exists(self.input):
            raise ConfigError, 'Input file is not where it is expected to be: "%s"' % self.input
        
        utils.check_dir(self.base_work_dir, clean_dir_content = False)
        utils.check_dir(self.dataset_root_dir, clean_dir_content = False)
Example #2
0
    def init_essential_files_and_directories(self):
        IS_RELATIVE = lambda d: not d.startswith('/')

        if len([
                True for item in [self.base_work_dir, self.input]
                if IS_RELATIVE(item)
        ]):
            raise ConfigError, 'All paths should be absolute (starting with a "/").'

        if not os.path.exists(self.input):
            raise ConfigError, 'Input file is not where it is expected to be: "%s"' % self.input

        utils.check_dir(self.base_work_dir, clean_dir_content=False)
        utils.check_dir(self.dataset_root_dir, clean_dir_content=False)
def clean(m):
    utils.check_dir(m.dirs["parts"], clean_dir_content=True)
Example #4
0
 def init_filter_files_and_directories(self, filter):
     utils.check_dir(filter.dirs['parts'])
Example #5
0
def clean(m):
    utils.check_dir(m.dirs['parts'], clean_dir_content=True)
Example #6
0
 def init_filter_files_and_directories(self, filter):
     utils.check_dir(filter.dirs['parts'])