Desc: 层次聚类算法的实现 Args: self : self width : 聚类mbr的阈值, 必须为int类型 Return: None Raise: None
(self, width)
| 443 | Desc: 层次聚类 |
| 444 | """ |
| 445 | def __init__(self, width): |
| 446 | """ |
| 447 | Desc: 层次聚类算法的实现 |
| 448 | Args: |
| 449 | self : self |
| 450 | width : 聚类mbr的阈值, 必须为int类型 |
| 451 | Return: |
| 452 | None |
| 453 | Raise: |
| 454 | None |
| 455 | """ |
| 456 | self.width = width |
| 457 | # 聚类的中间结果 |
| 458 | self.hcclusters = [] |
| 459 | # dict of (grid_id, HCCluster list) |
| 460 | self.grids = {} |
| 461 | |
| 462 | def run(self, points): |
| 463 | """ |
nothing calls this directly
no outgoing calls
no test coverage detected