def run(self, ips, imgs, para=None): geom = ips.roi.to_geom().convex_hull ips.roi = ROI(geom2shp(geom_flatten(geom)))
def run(self, ips, imgs, para=None): geom = ips.roi.to_geom().buffer(-para['r']) ips.roi = ROI(geom2shp(geom_flatten(geom)))
def run(self, ips, imgs, para=None): obj = mark2shp( self.app.manager('roi').get(name=para['name'])).to_geom() roi = geom_flatten(ips.roi.to_geom()) ips.roi = ROI(geom2shp(geom_flatten(roi.intersection(obj))))
def run(self, ips, imgs, para=None): obj = mark2shp( self.app.manager('roi').get(name=para['name'])).to_geom() roi = geom_flatten(ips.roi.to_geom()) ips.roi = ROI(geom2shp(geom_flatten(roi.symmetric_difference(obj))))
def run(self, ips, imgs, para=None): rect = Rectangle([0, 0, ips.shape[1], ips.shape[0]]) geom = rect.to_geom().difference(geom_flatten(ips.roi.to_geom())) ips.roi = ROI(geom2shp(geom_flatten(geom)))