示例#1
0
 def run(self):
     newpos = fruchterman_reingold_layout(graphview.graph,
                                          pos=pos,
                                          weight=weight,
                                          iterations=self.iterations,
                                          callback=self.callback)
     if not self.callback:  # update once at the end
         graphview.update_positions(newpos)
     graphview.animationFinished.emit()
示例#2
0
 def run(self):
     newpos = fruchterman_reingold_layout(graphview.graph,
                                          pos=pos,
                                          weight=weight,
                                          iterations=self.iterations,
                                          callback=self.callback)
     if not self.callback:  # update once at the end
         graphview.update_positions(newpos)
     graphview.animationFinished.emit()
 def run(self):
     newpos = fruchterman_reingold_layout(
         graphview.graph,
         pos=pos,
         weight=weight,
         iterations=self.iterations,
         sample_ratio=0.1,
         callback=self.callback,
         callback_rate=0.25)
     graphview.update_positions(newpos)
     graphview.animationFinished.emit()