推荐学习书目
› Learn Python the Hard Way
Python Sites
› PyPI - Python Package Index
› http://diveintopython.org/toc/index.html
› Pocoo
值得关注的项目
› PyPy
› Celery
› Jinja2
› Read the Docs
› gevent
› pyenv
› virtualenv
› Stackless Python
› Beautiful Soup
› 结巴中文分词
› Green Unicorn
› Sentry
› Shovel
› Pyflakes
› pytest
Python 编程
› pep8 Checker
Styles
› PEP 8
› Google Python Style Guide
› Code Style from The Hitchhiker's Guide
halicando
V2EX  ›  Python

PIL,imagefile上传图片报错Not a valid numbers of quantization tables. Should be between 2 and 4,什么情况?

  •  
  •   halicando · Sep 1, 2013 · 4351 views
    This topic created in 4772 days ago, the information mentioned may be changed or developed.
    6 replies  •  1970-01-01 08:00:00 +08:00
    paloalto
        1
    paloalto  
       Sep 1, 2013
    你是
    import Image
    还是
    from PIL import Image
    ?
    halicando
        2
    halicando  
    OP
       Sep 1, 2013
    @paloalto 直接 import ImageFile,Image
    paloalto
        3
    paloalto  
       Sep 1, 2013   ❤️ 1
    @halicando

    换成from PIL import Image试试呢?

    参考 https://github.com/python-imaging/Pillow/issues/210
    halicando
        4
    halicando  
    OP
       Sep 2, 2013
    后来重装了一下django就好了
    方法记下了,以防万一,谢谢。
    感谢已发送。
    halicando
        5
    halicando  
    OP
       Sep 2, 2013
    @paloalto
    后来重装了一下django就好了
    方法记下了,以防万一,谢谢。
    感谢已发送
    halicando
        6
    halicando  
    OP
       Sep 2, 2013
    @paloalto
    是重装了python,估计是版本冲突
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   1261 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 22ms · UTC 17:00 · PVG 01:00 · LAX 10:00 · JFK 13:00
    ♥ Do have faith in what you're doing.