Loading autocnet/cg/cg.py +3 −3 Original line number Diff line number Diff line Loading @@ -125,8 +125,8 @@ def vor(edge, clean_keys=[], s=30): Parameters ---------- edge : edge info edge : object An edge object clean_keys : list Of strings used to apply masks to omit correspondences Loading @@ -136,7 +136,7 @@ def vor(edge, clean_keys=[], s=30): Returns ------- vor : Voronoi vor : object Scipy Voronoi object voronoi_df : dataframe Loading autocnet/graph/edge.py +11 −0 Original line number Diff line number Diff line Loading @@ -772,6 +772,17 @@ class Edge(dict, MutableMapping): return total_overlap_coverage def compute_weights(self, clean_keys, **kwargs): """ Computes a voronoi diagram for the overlap between two images then gets the area of each polygon resulting in a voronoi weight. These weights are then appended to the matches dataframe. Parameters ---------- clean_keys : list Of strings used to apply masks to omit correspondences """ if self.matches is None: raise AttributeError('Matches have not been computed for this edge') voronoi = cg.vor(self, clean_keys, **kwargs) Loading Loading
autocnet/cg/cg.py +3 −3 Original line number Diff line number Diff line Loading @@ -125,8 +125,8 @@ def vor(edge, clean_keys=[], s=30): Parameters ---------- edge : edge info edge : object An edge object clean_keys : list Of strings used to apply masks to omit correspondences Loading @@ -136,7 +136,7 @@ def vor(edge, clean_keys=[], s=30): Returns ------- vor : Voronoi vor : object Scipy Voronoi object voronoi_df : dataframe Loading
autocnet/graph/edge.py +11 −0 Original line number Diff line number Diff line Loading @@ -772,6 +772,17 @@ class Edge(dict, MutableMapping): return total_overlap_coverage def compute_weights(self, clean_keys, **kwargs): """ Computes a voronoi diagram for the overlap between two images then gets the area of each polygon resulting in a voronoi weight. These weights are then appended to the matches dataframe. Parameters ---------- clean_keys : list Of strings used to apply masks to omit correspondences """ if self.matches is None: raise AttributeError('Matches have not been computed for this edge') voronoi = cg.vor(self, clean_keys, **kwargs) Loading