def newgalaxy(request, maindb, get_params, saslocal): release, bintype, template = get_params gal = Galaxy(request.param) gal.set_params(bintype=bintype, template=template) gal.set_filepaths() yield gal
def make_paths(request, rsync, mode, asurl, release): inputs = request.param if hasattr(request, 'param') else None rmode = 'url' if asurl else 'full' fullpaths = [] inputs = inputs if inputs else imagelist for plateifu in inputs: gal = Galaxy(plateifu) gal.set_params(release=release) gal.set_filepaths() name = 'mangaimage' if mode == 'local': path = rsync.__getattribute__(rmode)(name, **gal.access_kwargs) fullpaths.append(path) else: rsync.add(name, **gal.access_kwargs) rsync.set_stream() path = rsync.get_urls() if asurl else rsync.get_paths() fullpaths.extend(path) return fullpaths