clear_buffer_memory#
- class brainpy.math.clear_buffer_memory(platform=None, array=True, compilation=False)[source]#
Clear all on-device buffers.
This function will be very useful when you call models in a Python loop, because it can clear all cached arrays, and clear device memory.
Warning
This operation may cause errors when you use a deleted buffer. Therefore, regenerate data always.