在Google Colab中解压缩图像目录不会解压缩全部内容

编程入门 行业动态 更新时间:2024-10-28 01:17:14
本文介绍了在Google Colab中解压缩图像目录不会解压缩全部内容的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我正在尝试将75,000张图像的目录解压缩以训练CNN.使用进行解压缩时,

I'm trying to unzip a directory of 75,000 images for training a CNN. When unzipping using,

!unzip -uq "/content/BDD_gt_8045.zip" -d "/content/drive/My Drive/Ground_Truth"

并非所有图像都解压缩.我相信大约有5,000.我尝试做过几次,但后来有一些重复.我可以解压缩的图像数量有限制吗?

not all images unzip. I have about 5,000 I believe. I tried doing it several times but then I have some duplicates. Is there a limit to the number of images I can unzip?

目前,我对将所有文件都放入驱动器中以训练模型的方式仍然感到困惑.

I'm currently stuck on how else I'm meant to get all files into my drive to train the model.

推荐答案

Colab的默认'unzip'二进制文件无法正常工作.似乎在几个周期后会自动取消解压缩.运行最新版本的7z,您一切顺利.

Colab's default 'unzip' binary doesn't work as expected. It seems to cancel the unzipping automatically after a few cycles. Run latest version of 7z and you are good to go.

# To extract with full paths !7z x <filename.zip> # To extract all the files in the same folder (ignore paths) !7z e <filename.zip> # To specify output directory, use '-o' !7z x <filename.zip> -o '/content/drive/My Drive/Datasets/FashionMNIST'

更多推荐

在Google Colab中解压缩图像目录不会解压缩全部内容

本文发布于:2023-10-30 01:16:53,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1541335.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:解压缩   全部内容   图像   目录   Google

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!