且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

创建matplotlib图形后如何释放内存

更新时间:2023-02-02 21:09:54

您是否尝试过多次运行任务函数(在for中),以确保您的函数不会因芹菜而泄漏? 确保django.settings.DEBUG设置为False(当DEBUG = True时,连接对象将所有查询保存在内存中).

Did you try to run you task function several times (in a for) to be sure that not your function is leaking no matter of celery? Make sure that django.settings.DEBUG is set False( The connection object holds all queries in memmory when DEBUG=True).