LoginSignup
0
0

More than 5 years have passed since last update.

PNM > ppmファイル > 1行に出力されるRGB値はファイルによって異なるようだ > 1行70文字制限

Last updated at Posted at 2017-03-04
動作環境
GeForce GTX 1070 (8GB)
ASRock Z170M Pro4S [Intel Z170chipset]
Ubuntu 14.04 LTS desktop amd64
TensorFlow v0.11
cuDNN v5.1 for Linux
CUDA v8.0
Python 2.7.6
IPython 5.1.0 -- An enhanced Interactive Python.
gcc (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4
GNU bash, version 4.3.8(1)-release (x86_64-pc-linux-gnu)

http://qiita.com/7of9/items/1a04107f8af1e38e3969
にて気になった以下について調べた。

csvファイル出力時のカンマの数がおかしい。

2つの異なる単語をそれぞれ画像化したppmファイルを比べた。

tmp.ppm.idx4
...
173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 
173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 
173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 
tmp.ppm.idx5
...
173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 
173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 
173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 173 216 230 
173 216 230 173 216 230 173 216 230 

最後の行の項目数が異なる。
以下でもチェックしてみた。

$ head -n 100 tmp.ppm.idx5  | wc
    100    1870    7221
$ head -n 100 tmp.ppm.idx4  | wc
    100    1858    7197

100行目までの項目数が1870と1858で異なる。

No line should be longer than 70 characters.

1行が70文字を越さないように出力しているのかもしれない。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0