mirror of
https://github.com/ml-explore/mlx.git
synced 2025-09-09 06:14:03 +08:00
Even Faster I/O (#1369)
* try multithreading for faster IO * smaller batch size * Account for pread returning less than size * nit --------- Co-authored-by: Angelos Katharopoulos <a_katharopoulos@apple.com>
This commit is contained in:
@@ -146,6 +146,11 @@ class PyFileReader : public io::Reader {
|
||||
}
|
||||
}
|
||||
|
||||
void read(char* data, size_t n, size_t offset) override {
|
||||
seek(offset);
|
||||
read(data, n);
|
||||
}
|
||||
|
||||
std::string label() const override {
|
||||
return "python file object";
|
||||
}
|
||||
|
Reference in New Issue
Block a user