質問するログイン新規登録

質問編集履歴

3

タイトル変更

2021/09/07 22:22

投稿

xozeit
xozeit

スコア19

title CHANGED
@@ -1,1 +1,1 @@
1
- mnistの画像を表示させたい
1
+ WSL環境でPIL(Pillow)を使ってmnistの画像を表示させたい
body CHANGED
File without changes

2

タグ追加(WSL)

2021/09/07 22:22

投稿

xozeit
xozeit

スコア19

title CHANGED
File without changes
body CHANGED
File without changes

1

■210907追記

2021/09/07 22:19

投稿

xozeit
xozeit

スコア19

title CHANGED
File without changes
body CHANGED
@@ -178,4 +178,62 @@
178
178
  <PIL.Image.Image image mode=L size=28x28 at 0x7F5920077AF0>
179
179
  <class 'numpy.ndarray'>
180
180
 
181
- ```
181
+ ```
182
+
183
+ ■210907追記
184
+
185
+ imagemagickはなぜかインストールがNot Foundで上手くいきませんでした。
186
+ ```
187
+ kataoka@DESKTOP-IJMM4SU:/mnt/c/Users/tiezo/Desktop/python/deep-learning-from-scratch/ch03$ sudo apt install imagemagick
188
+ [sudo] password for kataoka:
189
+ Reading package lists... Done
190
+ Building dependency tree
191
+ Reading state information... Done
192
+ The following packages were automatically installed and are no longer required:
193
+ bridge-utils libfprint-2-tod1 ubuntu-fan
194
+ Use 'sudo apt autoremove' to remove them.
195
+ The following additional packages will be installed:
196
+ gsfonts imagemagick-6-common imagemagick-6.q16 libdjvulibre-text libdjvulibre21 libfftw3-double3 libilmbase24 liblqr-1-0 libmagickcore-6.q16-6 libmagickcore-6.q16-6-extra libmagickwand-6.q16-6
197
+ libnetpbm10 libopenexr24 libwmf0.2-7 netpbm
198
+ Suggested packages:
199
+ imagemagick-doc autotrace cups-bsd | lpr | lprng enscript ffmpeg gimp gnuplot grads graphviz hp2xx html2ps libwmf-bin mplayer povray radiance texlive-base-bin transfig ufraw-batch libfftw3-bin
200
+ libfftw3-dev inkscape libjxr-tools libwmf0.2-7-gtk
201
+ The following NEW packages will be installed:
202
+ gsfonts imagemagick imagemagick-6-common imagemagick-6.q16 libdjvulibre-text libdjvulibre21 libfftw3-double3 libilmbase24 liblqr-1-0 libmagickcore-6.q16-6 libmagickcore-6.q16-6-extra
203
+ libmagickwand-6.q16-6 libnetpbm10 libopenexr24 libwmf0.2-7 netpbm
204
+ 0 upgraded, 16 newly installed, 0 to remove and 59 not upgraded.
205
+ Need to get 2513 kB/8898 kB of archives.
206
+ After this operation, 28.0 MB of additional disk space will be used.
207
+ Do you want to continue? [Y/n] y
208
+ Ign:1 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 imagemagick-6-common all 8:6.9.10.23+dfsg-2.1ubuntu11.1
209
+ Ign:2 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 libmagickcore-6.q16-6 amd64 8:6.9.10.23+dfsg-2.1ubuntu11.1
210
+ Ign:3 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 libmagickwand-6.q16-6 amd64 8:6.9.10.23+dfsg-2.1ubuntu11.1
211
+ Ign:4 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 imagemagick-6.q16 amd64 8:6.9.10.23+dfsg-2.1ubuntu11.1
212
+ Ign:5 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 imagemagick amd64 8:6.9.10.23+dfsg-2.1ubuntu11.1
213
+ Ign:6 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 libmagickcore-6.q16-6-extra amd64 8:6.9.10.23+dfsg-2.1ubuntu11.1
214
+ Ign:1 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 imagemagick-6-common all 8:6.9.10.23+dfsg-2.1ubuntu11.1
215
+ Err:2 http://security.ubuntu.com/ubuntu focal-updates/universe amd64 libmagickcore-6.q16-6 amd64 8:6.9.10.23+dfsg-2.1ubuntu11.1
216
+ 404 Not Found [IP: 2001:67c:1360:8001::23 80]
217
+ Err:3 http://security.ubuntu.com/ubuntu focal-updates/universe amd64 libmagickwand-6.q16-6 amd64 8:6.9.10.23+dfsg-2.1ubuntu11.1
218
+ 404 Not Found [IP: 2001:67c:1360:8001::23 80]
219
+ Err:4 http://security.ubuntu.com/ubuntu focal-updates/universe amd64 imagemagick-6.q16 amd64 8:6.9.10.23+dfsg-2.1ubuntu11.1
220
+ 404 Not Found [IP: 2001:67c:1360:8001::23 80]
221
+ Err:5 http://security.ubuntu.com/ubuntu focal-updates/universe amd64 imagemagick amd64 8:6.9.10.23+dfsg-2.1ubuntu11.1
222
+ 404 Not Found [IP: 2001:67c:1360:8001::23 80]
223
+ Err:6 http://security.ubuntu.com/ubuntu focal-updates/universe amd64 libmagickcore-6.q16-6-extra amd64 8:6.9.10.23+dfsg-2.1ubuntu11.1
224
+ 404 Not Found [IP: 2001:67c:1360:8001::23 80]
225
+ Ign:1 http://security.ubuntu.com/ubuntu focal-updates/universe amd64 imagemagick-6-common all 8:6.9.10.23+dfsg-2.1ubuntu11.1
226
+ Err:1 http://security.ubuntu.com/ubuntu focal-updates/universe amd64 imagemagick-6-common all 8:6.9.10.23+dfsg-2.1ubuntu11.1
227
+ 404 Not Found [IP: 2001:67c:1360:8001::23 80]
228
+ E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/i/imagemagick/imagemagick-6-common_6.9.10.23+dfsg-2.1ubuntu11.1_all.deb 404 Not Found [IP: 2001:67c:1360:8001::23 80]
229
+ E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/i/imagemagick/libmagickcore-6.q16-6_6.9.10.23+dfsg-2.1ubuntu11.1_amd64.deb 404 Not Found [IP: 2001:67c:1360:8001::23 80]
230
+ E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/i/imagemagick/libmagickwand-6.q16-6_6.9.10.23+dfsg-2.1ubuntu11.1_amd64.deb 404 Not Found [IP: 2001:67c:1360:8001::23 80]
231
+ E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/i/imagemagick/imagemagick-6.q16_6.9.10.23+dfsg-2.1ubuntu11.1_amd64.deb 404 Not Found [IP: 2001:67c:1360:8001::23 80]
232
+ E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/i/imagemagick/imagemagick_6.9.10.23+dfsg-2.1ubuntu11.1_amd64.deb 404 Not Found [IP: 2001:67c:1360:8001::23 80]
233
+ E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/universe/i/imagemagick/libmagickcore-6.q16-6-extra_6.9.10.23+dfsg-2.1ubuntu11.1_amd64.deb 404 Not Found [IP: 2001:67c:1360:8001::23 80]
234
+ E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
235
+
236
+ ```
237
+
238
+ 一方matplotlibに変えたら表示できました!ありがとうございます。
239
+ ただ本に記載されているのを毎回デバッグするのも大変なので出来れば原因把握したいのですが、何が考えられるでしょうか?