You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I run Session_4/4_basic_allocate_example.ipynb on my jupyter notebook.
The memory reduced even after del buffer
I don't know why and now I have to use the Linux command echo 1 > /proc/sys/vm/drop_caches on the terminal to free cache, but it's not useful all the time.
I have no idea what allocate have done to my ram.
The text was updated successfully, but these errors were encountered:
inport allocate # replace Xlnk
import gc
weight_buffer = allocate(shape=(25470896,), dtype=np.uint32) # allocate 100M memory
params_w = np.fromfile("yolo.bin", dtype=np.uint32) # read the file
np.copyto(weight_buffer, params_w) # load the file to the 100M memory
del params_w # will not be used again, so delete it to free memory
gc.collect()
I run
Session_4/4_basic_allocate_example.ipynb
on my jupyter notebook.The memory reduced even after
del buffer
I don't know why and now I have to use the Linux command
echo 1 > /proc/sys/vm/drop_caches
on the terminal to free cache, but it's not useful all the time.I have no idea what
allocate
have done to my ram.The text was updated successfully, but these errors were encountered: