From fb138dbcd2081fd6b63b45a2eeef3241a7c93778 Mon Sep 17 00:00:00 2001 From: Rich Tong <1782087+richtong@users.noreply.github.com> Date: Mon, 13 Jun 2022 13:48:47 -0700 Subject: [PATCH] feat: Update README, customize for netdrones --- FastDepth-CoreML.xcodeproj/project.pbxproj | 8 +-- .../UserInterfaceState.xcuserstate | Bin 0 -> 13345 bytes .../xcschemes/xcschememanagement.plist | 14 ++++ README.md | 63 ++++++++++++++++-- 4 files changed, 77 insertions(+), 8 deletions(-) create mode 100644 FastDepth-CoreML.xcodeproj/project.xcworkspace/xcuserdata/rich.xcuserdatad/UserInterfaceState.xcuserstate create mode 100644 FastDepth-CoreML.xcodeproj/xcuserdata/rich.xcuserdatad/xcschemes/xcschememanagement.plist diff --git a/FastDepth-CoreML.xcodeproj/project.pbxproj b/FastDepth-CoreML.xcodeproj/project.pbxproj index 65cee27..bd5ba49 100644 --- a/FastDepth-CoreML.xcodeproj/project.pbxproj +++ b/FastDepth-CoreML.xcodeproj/project.pbxproj @@ -368,7 +368,7 @@ CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 0; DERIVE_MACCATALYST_PRODUCT_BUNDLE_IDENTIFIER = YES; - DEVELOPMENT_TEAM = 9QJ8M25J77; + DEVELOPMENT_TEAM = 7W9SLRSLX5; INFOPLIST_FILE = "FastDepth-CoreML/Info.plist"; IPHONEOS_DEPLOYMENT_TARGET = 13.0; LD_RUNPATH_SEARCH_PATHS = ( @@ -376,7 +376,7 @@ "@executable_path/Frameworks", ); MARKETING_VERSION = 0; - PRODUCT_BUNDLE_IDENTIFIER = com.coreml.fastdepth; + PRODUCT_BUNDLE_IDENTIFIER = com.netdronesai.fastpath; PRODUCT_NAME = "$(TARGET_NAME)"; SUPPORTS_MACCATALYST = YES; SWIFT_VERSION = 5.0; @@ -392,7 +392,7 @@ CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 0; DERIVE_MACCATALYST_PRODUCT_BUNDLE_IDENTIFIER = YES; - DEVELOPMENT_TEAM = 9QJ8M25J77; + DEVELOPMENT_TEAM = 7W9SLRSLX5; INFOPLIST_FILE = "FastDepth-CoreML/Info.plist"; IPHONEOS_DEPLOYMENT_TARGET = 13.0; LD_RUNPATH_SEARCH_PATHS = ( @@ -400,7 +400,7 @@ "@executable_path/Frameworks", ); MARKETING_VERSION = 0; - PRODUCT_BUNDLE_IDENTIFIER = com.coreml.fastdepth; + PRODUCT_BUNDLE_IDENTIFIER = com.netdronesai.fastpath; PRODUCT_NAME = "$(TARGET_NAME)"; SUPPORTS_MACCATALYST = YES; SWIFT_VERSION = 5.0; diff --git a/FastDepth-CoreML.xcodeproj/project.xcworkspace/xcuserdata/rich.xcuserdatad/UserInterfaceState.xcuserstate b/FastDepth-CoreML.xcodeproj/project.xcworkspace/xcuserdata/rich.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 0000000000000000000000000000000000000000..5ef6ccf050de26aec143c8970c1aed695af36d06 GIT binary patch literal 13345 zcmdsdd3;mF`uEJ7G)-EdCuwMtG;Nb+1EKp42;HGj+S0V8ltM_`Ly5FWP14eW$W#T~ z7rcsIuSyF7g3EQe?ua`Iu2fu6+%#AubCR@$>b;-)zVAP8`HSv&oiyvoo;_1Bja_15kVZ1p$H^LktnLk(kuAT<%XwvOTgRRWbwA1 zBeVtlYJ@j!bMi6Ojs-%$&|Vzu^cqqiWrHK&3J4V6t->l4jV7RYq(wTEjxtat%0k&F z2j!wXl#dEfA)14VPz9<&3y}jk(F){3t*8yPqgALAb)!Dij|R{M=t6W6+K4ViSDGfJx;_)*o3Wk8cxSqI1kUm zm3Tg0fUEFAT#ak63%BAn+>Qmj5_jNLIDmU_FJ6QD@I`nd-h?;fi}B_73Vbd86TSi8 zh;P9=@h-d@KZBpe&*203dHe!Ch!5cx@k{t+{0e>*592rR+xQ*)EiIy11bdpNaNIJCarlPaZG&CKh(n&Oi zPNCE3Y`Tmtrz@z78emx^KEbuR+w1lO{KahncQ0r~yOY8zg^90I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={q(4e*u0Ts?-1g literal 0 HcmV?d00001 diff --git a/FastDepth-CoreML.xcodeproj/xcuserdata/rich.xcuserdatad/xcschemes/xcschememanagement.plist b/FastDepth-CoreML.xcodeproj/xcuserdata/rich.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 0000000..af58d4c --- /dev/null +++ b/FastDepth-CoreML.xcodeproj/xcuserdata/rich.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,14 @@ + + + + + SchemeUserState + + FastDepth-CoreML.xcscheme_^#shared#^_ + + orderHint + 0 + + + + diff --git a/README.md b/README.md index 3f0c98f..e388c44 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,62 @@ # FastDepth-CoreML -This is a CoreML version of [FastDepth: Fast Monocular Depth Estimation on Embedded Systems](https://github.com/dwofk/fast-depth). I do not guarantee the correctness of my conversion. -The iOS project is based on tucan9389's [DepthPrediction](https://github.com/tucan9389/DepthPrediction-CoreML), but with [CoreMLHelpers](https://github.com/hollance/CoreMLHelpers/) for convenience. -# Example +This is a CoreML version of [FastDepth: Fast Monocular Depth Estimation on +Embedded Systems](https://github.com/dwofk/fast-depth). I do not guarantee the +correctness of my conversion. +The iOS project is based on tucan9389's +[DepthPrediction](https://github.com/tucan9389/DepthPrediction-CoreML), but +with [CoreMLHelpers](https://github.com/hollance/CoreMLHelpers/) for +convenience. + +## Installation + +Fork this repo because you are going to need to change the certificates so that +you can download this on your own phone. So to make this work for you: + +1. Fork this repo and create your own branch and switch to it +1. Create an Apple identifier and login to the Apple Developer website +1. In Xcode, go to Preferences/Accounts and add your Apple ID. If it is just a + personal one, you should see something like your ID, then the Team should be + *Your Name* (Personal Team) +1. Then go to the upper left and click on the leftmost icon, the Project + Navigator button, click on the top left item which is the project + `FastDepth-CoreML` and then Signing & Capabilities +1. You will see in the Signing section in the Team dropdown, something like + `Unknown Name (9QJ*M25J77)` click Team and you should see your team. +1. You should now see at the bottom in the Status, "Failed to register the + Bundle" and that is because you have to create a new identifier which by + default is com.coremi.fastdepth because you don't own that URL and you can't + create bundles without owning it. Use Reverse DNS notation of a domain that + you own to create a valid bundle identifier, for example if you are the + owner of tongfamily.com then you would type something like + like `com.tongfamily.fastdepth`. Note that the bundle idenfier is pretty + picky, so for instance if you have `netdron.es` then it will not accept + `ex.netdron.fastdepth`, so use .com as that seems to work ok. I'm sure other + TLD will as well, but if it works, the errors should disappear +1. Now go to Windows/Devices and Simulators and make sure your iPhone is + plugged into your computer. Simulation as an aside does not work with this + application, so you need a live phone. +1. Click on Device tab and you should see your device there. You will have to + wait while the yellow banner on top tells you about what's going on and when + it is ready. note that if you have Apple Watch tied to your phone, it will + want to trust set for the device as well. You can ignore this as you not + using an Apple Watch. +1. Now to to the main screen and in the icon bar you see a selection of where + to run it. Click on this and select your phone. Now press play button or go + to the menu and choose Product > Run and this should compile and load the + application to your device. +1. The application will now download a certificate and then you need to go to + Settings > General > VPN & Device Management on your phone and you should + see in the Developer App section something like "Apple Development: *your + email*", then click on the right arrow and choose Trust to trust + applications that come from you. +1. The application should then run with two windows of the real image and then + the depth map in grey where white means closer to the camera and darker + means more distance. +1. There is no save facility here, so if you want to save the run, then pull + down on the Control Center and choose the Record button. + +## Example + Recorded on an iPhone X. -![](Assets/demo.gif) \ No newline at end of file +![Demo Video](Assets/demo.gif)