Comments (6)
from simpleimage.
这个就是报异常的图片,希望能给出测试解决方案
from simpleimage.
非常抱歉,目前没有任何能处理所有图片格式,包括adobe photoshopbn 也存在打不开的图片,但换一种工具就能浏览,我们能做的只是改最大
努力去解析图片。但是万一解析不了,可以在捕获异常中换一种方式转换图片再试试。
在 2015年4月18日,下午4:42,sixiong [email protected] 写道:
这个就是报异常的图片,希望能给出测试解决方案
—
Reply to this email directly or view it on GitHub #6 (comment).
from simpleimage.
您提到的换一种方式转换图片指的是?
这个代码换一种方式进行转化吗
from simpleimage.
你好,这个问题已经查明是一个float精度丢失造成的bug。
if (idxDir < 0.0) {
idxDir += directionCount;
}
directionCount = 8(int)
idxDir 是float.
结果是 idxDir 很小的负数是,idxDir < 0.0成立,但是 idxDir += 8;还是8.0,现在修改成double,问题已经解决。
原来的实现是都是用double,精度很高,准确性也很高,但是计算时太占用内存,我折中一下,将大多数的double优化成float,可以节省一半的内存空间。
但是优化后这里精度就丢失了,出现了bug。
建议如果不在意内存,将实现中所有float替换成double,这样精度高,识别准确率也很高。
在 2015年4月20日,上午9:17,axman [email protected] 写道:
将BuffreadImg img转换成为其它格式,比如从jpg另存为png再重新读出来试试。
在 2015年4月19日,下午8:50,sixiong <[email protected] mailto:[email protected]> 写道:
您提到的换一种方式转换图片指的是?
https://cloud.githubusercontent.com/assets/8112710/7219488/b8563690-e6d5-11e4-807c-35c68da2d982.png
这个代码换一种方式进行转化吗—
Reply to this email directly or view it on GitHub #6 (comment).
from simpleimage.
好的,谢谢
from simpleimage.
Related Issues (20)
- 安装问题 HOT 2
- 哪里有详尽的api文档? HOT 4
- 比如图片 750 * 670 ,我要750*750的,根据这个new ScaleParameter(750, 750)类的设置, 最后得到的图片还是,750 * 670 而我想要的是,670 * 670 这样 HOT 3
- 图片无法放大?
- FontManager.getFont 返回null HOT 2
- Missing artifact com.alibaba:simpleimage.core:jar:1.2.4 HOT 1
- FontManager.getFont("方正黑体");这个方法返回值为null HOT 1
- 下载1.2.4版本jar包
- 大爷们 哪儿有这个jar包
- 配置maven仓库,编译失败 HOT 1
- 请补上License声明 HOT 1
- 这玩意几千年没有更新了?
- simpleimage WatermarkParameter水印合成之后图片像素被破坏 图片变黑
- Any performance test between simpleImage and Thumbnails
- Missing jai core and jai codec depencies for maven/gradle!
- Please consider updating readme HOT 1
- Is it possible to support jdk7 try-with-resource?
- Pls submit the jar to maven responsitory
- png转换成jpg格式有问题,
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from simpleimage.