def set_data_dir(directory=None, create=False, save=False):
 if (directory is None):
  directory = _data_path
  if (_data_path is None):
   raise IOError('default path cannot be determined, please set it manually (directory != None)')
 if (not op.isdir(directory)):
  if (not create):
   raise IOError(('directory "%s" does not exist, perhaps try create=True to create it?' % directory))
  os.mkdir(directory)
 config.update(data_path=directory)
 if save:
  save_config(data_path=directory)

def set_data_dir ( directory = None , create = False , save = False ) : if ( directory is None ) : directory = _data_path if ( _data_path is None ) : raise IOError ( 'default path cannot be determined, please set it manually (directory != None)' ) if ( not op . isdir ( directory ) ) : if ( not create ) : raise IOError ( ( 'directory "%s" does not exist, perhaps try create=True to create it?' % directory ) ) os . mkdir ( directory ) config . update ( data_path = directory ) if save : save_config ( data_path = directory )
set vispy data download directory parameters directory : str | none the directory to use .