clear_cache接口

接口功能

清理cache。(属于内部调度接口,暂不支持对外功能。)

接口实现

1
2
3
4
def clear_cache(self):
    del self.cache_pool
    torch.npu.empty_cache()
    gc.collect()