HKUST-Aerial-Robotics / VINS-Mobile

Monocular Visual-Inertial State Estimator on Mobile Phones
GNU General Public License v3.0
1.26k stars 524 forks source link

VINS-mobile by iPhone 8 #104

Open KangTeng opened 6 years ago

KangTeng commented 6 years ago

I obtain intrinsic parameters such as FOCUS_LENGTH_Y, FOCUS_LENGTH_X, PY, PX and get extrinsic parameters likes TIC_X,TIC_Y,TIC_Z by monocular camera calibration. After the compilation is successful, run the code on the IPhone8, the interface stays at 0% of the initialization (Feature points can be refreshed).

dreness commented 6 years ago

@kangteng - would you mind sharing your iphone8 camera intrinsics and a brief description of how you obtained them? I am currently trying to get this project working with my 8+, and although I have found a couple ways to derive the intrinsics, the results aren’t as consistent as I’d like...

KangTeng commented 6 years ago

I can run VINS-mobile successful on the IPhone8 and IPhone8+, you can try the intrinsics of IPhone8+ like this:FOCUS_LENGTH_X=530.233;FOCUS_LENGTH_Y=531.082;PX=250.286;PY=316.520.(I don't use the raw data, however, it is obtained by multiplying a factor by Comparing the intrinsics of iphone7 in the source code and the measured data by monocular camera calibration)

------------------ 原始邮件 ------------------ 发件人: "Andre LaBranche";notifications@github.com; 发送时间: 2018年1月29日(星期一) 中午11:37 收件人: "HKUST-Aerial-Robotics/VINS-Mobile"VINS-Mobile@noreply.github.com; 抄送: "我若为王"576454399@qq.com; "Mention"mention@noreply.github.com; 主题: Re: [HKUST-Aerial-Robotics/VINS-Mobile] VINS-mobile by iPhone 8(#104)

@KangTeng - would you mind sharing your iphone8 camera intrinsics and a brief description of how you obtained them? I am currently trying to get this project working with my 8+, and although I have found a couple ways to derive the intrinsics, the results aren’t as consistent as I’d like...

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

JunYiShih commented 5 years ago

I have built the app successfully in my iPhone8. But it shows unsupported device and the initializing is always 0%. How did you solve this problem?

Fdevmsy commented 4 years ago

I have successfully run this program on iPhone 8 and upper (iPhone Xs, etc). It can be easily modified by the following:

  1. Globally search the keyword "iphone7", you will find it in 3 files: global_param.cpp, global_param.h and ViewController.mm
  2. For each place, either add the name of your own device to the list, for example, "iPhone8", or copy and paste the block of code for "iphone7" and replace the name with "iPhone8".
  3. Specifically, in global_param.cpp, copy and paste the whole "case iPhone7", change the name to "iPhone8". For the camera parameters, just calibrate your camera and fill them into the corresponding places. (If you are lazy, you can just copy the same parameters of "case iPhone7P", there's no huge difference in parameters between different iPhones. This would at least make your program work).

Good luck.