您可以找到该类的所有实例:for obj in gc.get_objects(): if isinstance(obj, BigClass): # DEBUG IT为了调试实际对象以及它们是如何引用的:for ref in gc.get_referrers(obj): # Should probably filter here to reduce the amount of data printed and avoid printing locals() as well print(ref)