Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ rand = "0.8" # weight init, dropout masks, shuffling
rand_distr = "0.4" # normal distribution
rayon = "1.8" # data parallelism on the CPU paths
libm = "0.2" # erff, for exact GELU
ureq = "2.9" # dataset download
ureq = "3.4" # dataset download
flate2 = "1.0" # dataset decompression

[build-dependencies]
Expand Down
5 changes: 4 additions & 1 deletion src/data/mnist.rs
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,10 @@ fn download_missing(cache: &Path, files: &[&str]) -> Result<()> {
.map_err(|e| Error::Dataset(format!("could not fetch {url}: {e}")))?;

let mut compressed = Vec::new();
response.into_reader().read_to_end(&mut compressed)?;
response
.into_body()
.into_reader()
.read_to_end(&mut compressed)?;
let mut raw = Vec::new();
flate2::read::GzDecoder::new(&compressed[..]).read_to_end(&mut raw)?;

Expand Down
Loading