def get_overlay(self, subject, otype='rois', **kwargs):
        from . import svgroi
        pts, polys = self.get_surf(subject, "flat", merge=True, nudge=True)
        if otype in ["rois", "cutouts", "sulci"] or isinstance(otype, (list,tuple)):
            # Assumes that all lists or tuples will only consist of "rois","cutouts",and "sulci"...
            # Prevents combining external files with sulci, e.g. 
            svgfile = self.get_paths(subject)["rois"]
            if self.auxfile is not None:
                try:
                    tf = self.auxfile.get_overlay(subject, otype) # kwargs??
                    svgfile = tf.name
                except (AttributeError, __HOLE__):
                    # NOTE: This is better error handling, but does not account for
                    # case in which self.auxfile is None - when is that?? I (ML) think
                    # it only comes up with new svg layer variants in extra_layers branch...
                    # svgfile = self.get_paths(subject)["rois"]
                    # Layer type does not exist or has been temporarily removed
                    pass                    
            if 'pts' in kwargs:
                pts = kwargs['pts']
                del kwargs['pts']
            return svgroi.get_roipack(svgfile, pts, polys, layer=otype, **kwargs)
        if otype == "external":
            layer = kwargs['layer']
            del kwargs['layer']
            svgfile = kwargs["svgfile"]
            del kwargs["svgfile"]
            if 'pts' in kwargs:
                pts = kwargs['pts']
                del kwargs['pts']
            return svgroi.get_roipack(svgfile, pts, polys, layer=layer,**kwargs)

        raise TypeError('Invalid overlay type')
dataset/ETHPy150Open gallantlab/pycortex/cortex/database.py/Database.get_overlay