Quantcast
Channel: Recent Questions - Stack Overflow
Viewing all articles
Browse latest Browse all 12111

get 'int' data when I load .npy using numpy or pickle

$
0
0

I got an .npy file, but it doesn't have an extension. When I use np.load, I get an int. How do I open it?I tried to change numpy version, but it doesn't help.

>>> import numpy as np>>> a=np.load('/opt/data/private/msl/data_thumos/Rgb_TestPJ2_All/video_test_0000006',allow_pickle=True)>>> a119547037146038801333356

I'm sure this is a npy file, but I don't know how to get the data。

I tried from file, I get array with the shape of (10211,), which lose the original shape.

`# with open(file_path, 'rb') as f:#     data = np.fromfile(f, dtype=np.float32)`

Viewing all articles
Browse latest Browse all 12111

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>