不是JPEG文件:开头为0x0a 0x4c错误 [英] Not a JPEG file: starts with 0x0a 0x4c Error

查看:138
本文介绍了不是JPEG文件:开头为0x0a 0x4c错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试导入一堆.jpeg文件格式的图像. 但是我遇到了错误

I'm trying to import a bunch of images of .jpeg file format. However I'm getting the error

Not a JPEG file: starts with 0x0a 0x4c

现在,我知道0x89 0x50是.png文件的启动方式.但是我不明白0x0a 0x4c代表什么.

Now, I know 0x89 0x50 is how .png files start. But I can't understand what 0x0a 0x4c represents.

我还在终端上运行了file image001.jpeg命令,它给了我

I also ran the file image001.jpeg command on the terminal and it gave me

JPEG image data, JFIF standard 1.01.

此外,当我导入这些图像组时,每次都会针对不同的文件(而不是相同的文件)抛出此错误.因此,我想这不是文件损坏的问题.

Also, when I'm importing these group of images, this error is thrown for different files each time, not the same ones. So, I guess it isn't an issue of the file being corrupted.

如果有帮助,则通过opencvimwrite()功能生成图像文件并将其保存在硬盘上.

If it helps, the image files were generated and saved on the hard disk through the imwrite() function of opencv.

谢谢

使用ImageMagick,将获得以下详细输出.

Using ImageMagick, the following verbose output is obtained.

Image: /Users/deathstroke/Desktop/lipRead/VidTIMIT/mwbt0/video/sx383/roi081.jpeg
  Format: JPEG (Joint Photographic Experts Group JFIF format)
  Mime type: image/jpeg
  Class: DirectClass
  Geometry: 68x39+0+0
  Units: Undefined
  Type: TrueColor
  Endianess: Undefined
  Colorspace: sRGB
  Depth: 8-bit
  Channel depth:
    red: 8-bit
    green: 8-bit
    blue: 8-bit
  Channel statistics:
    Pixels: 2652
    Red:
      min: 0 (0)
      max: 223 (0.87451)
      mean: 139.207 (0.54591)
      standard deviation: 44.1822 (0.173263)
      kurtosis: 0.798663
      skewness: -1.01178
      entropy: 0.942718
    Green:
      min: 0 (0)
      max: 159 (0.623529)
      mean: 87.1161 (0.341632)
      standard deviation: 33.4156 (0.131041)
      kurtosis: -0.162594
      skewness: -0.485596
      entropy: 0.955489
    Blue:
      min: 0 (0)
      max: 249 (0.976471)
      mean: 73.9367 (0.289948)
      standard deviation: 43.7079 (0.171403)
      kurtosis: 2.38585
      skewness: 1.43844
      entropy: 0.917047
  Image statistics:
    Overall:
      min: 0 (0)
      max: 249 (0.976471)
      mean: 100.087 (0.392496)
      standard deviation: 40.7392 (0.159761)
      kurtosis: 2.09684
      skewness: 0.445232
      entropy: 0.938418
  Rendering intent: Perceptual
  Gamma: 0.454545
  Chromaticity:
    red primary: (0.64,0.33)
    green primary: (0.3,0.6)
    blue primary: (0.15,0.06)
    white point: (0.3127,0.329)
  Background color: white
  Border color: srgb(223,223,223)
  Matte color: grey74
  Transparent color: black
  Interlace: None
  Intensity: Undefined
  Compose: Over
  Page geometry: 68x39+0+0
  Dispose: Undefined
  Iterations: 0
  Compression: JPEG
  Quality: 95
  Orientation: Undefined
  Properties:
    date:create: 2016-04-15T23:19:32+06:00
    date:modify: 2016-04-15T23:19:32+06:00
    jpeg:colorspace: 2
    jpeg:sampling-factor: 2x2,1x1,1x1
    signature: d3f2c14b57043efd4edbf719dfe769aded504df16c5b9fc8ee436d7551993221
  Artifacts:
    filename: /Users/deathstroke/Desktop/lipRead/VidTIMIT/mwbt0/video/sx383/roi081.jpeg
    verbose: true
  Tainted: False
  Filesize: 1.81KB
  Number pixels: 2.65K
  Pixels per second: 265KB
  User time: 0.000u
  Elapsed time: 0:01.009
  Version: ImageMagick 6.9.3-7 Q16 x86_64 2016-03-27 http://www.imagemagick.org

推荐答案

JPEG流以SOI标记FF D8开始. JFIF文件后跟一个APP0标记FF E0.

A JPEG Stream starts with an SOI marker FF D8. A JFIF file follows that with an APP0 marker FF E0.

您完全有可能在数据中的某处嵌入了有效的JPEG流,并且某些应用程序会跳过非jpeg数据,直到它们到达SOI标记,而其他应用程序则在抽取无关数据.

It is entirely possible that you have a valid JPEG stream embedded somewhere in your data and that some applications are skipping over the non-jpeg data until they reach the SOI marker while other are puking on extraneous data.

这篇关于不是JPEG文件:开头为0x0a 0x4c错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆