mlx.core.get_peak_memory

mlx.core.get_peak_memory#

get_peak_memory() int#

获取已使用内存的峰值(以字节为单位)。

记录自程序执行开始或上次调用 reset_peak_memory() 以来使用的最大内存量。