MCPcopy Create free account
hub / github.com/ml-explore/mlx-data / check_stream

Function check_stream

mlx/data/core/Numpy.cpp:10–18  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

8namespace {
9
10static void check_stream(
11 const std::istream& f,
12 const std::string filename,
13 const std::string action) {
14 if (!f.good()) {
15 throw std::runtime_error(
16 std::string("loadNumpy: error " + action + " file <") + filename + ">");
17 }
18}
19
20/// structure of the npy file format string (a string-serialized python
21/// dictionary), see parseNumpyFormat

Callers 1

load_numpyFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected