-
Notifications
You must be signed in to change notification settings - Fork 475
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BD 算法偏移系数有误 #43
Comments
BD应该是别人贡献的,我开始的时候并没有打算包含BD的算法实现。毕竟百度的东西,没人支持也就没人用了对吧。 |
我确认一下这个 |
I saw this issue in the python implementation. Are there some good test Points I can be used for testing wgs to bd? I get too large of errors in the current test data I just want to make sure it's ok |
Nah just use the constant in https://github.com/Artoria2e5/PRCoords/blob/05d1c12/js/PRCoords.js#L145-L158. It's really just pi times 3000: they missed the 3000. Play around in https://artoria2e5.github.io/PRCoords/demo if you want to. |
And since you are doing a Matlab implementation, I strongly recommend that you read caijun's R implementation at https://github.com/caijun/geoChina. Solid work by, well, a math-y R programmer I guess. |
Changing pi to X_PI did reduce the error rate (See testcases at https://gist.github.com/w1ndy/5236bca0654f472c8cffa038406441ed). I've fixed the python implementation and released a new package. |
Before:
After:
|
BD 的原始泄出实现中有一个
x_pi
变量,指的是3000 / 180 * Math.PI
,eviltransform 抄过来变成了Math.PI
。想要测试的话尽管上 http://lbsyun.baidu.com/index.php?title=webapi/guide/changeposition 去比。
The text was updated successfully, but these errors were encountered: