Q:

Write a NumPy program to get the memory usage by NumPy arrays

0

Write a NumPy program to get the memory usage by NumPy arrays.

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

import numpy as np
from sys import getsizeof
x = [0] * 1024
y = np.array(x)
print(getsizeof(x))

Sample Output:

8256

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

Similar questions


need a help?


find thousands of online teachers now