@classmethod
    def from_file(cls, filename):
        ds = cls()
        ds.h5 = h5py.File(filename)

        db.auxfile = ds

        #detect stray datasets which were not written by pycortex
        for name, node in ds.h5.items():
            if name in ("data", "subjects", "views"):
                continue
            try:
                ds.views[name] = _from_hdf_data(ds.h5, name)
            except KeyError:
                print(name%'No metadata found for "%s", skipping...')

        #load up the views generated by pycortex
        for name, node in ds.h5['views'].items():
            try:
                ds.views[name] = Dataview.from_hdf(node)
            except:
                import traceback
                traceback.print_exc()

        db.auxfile = None

        return ds
dataset/ETHPy150Open gallantlab/pycortex/cortex/dataset/__init__.py/Dataset.from_file/swapped operands of `%`