Commit 4d2eb396 authored by Nguyễn Văn An's avatar Nguyễn Văn An

update model

parents a67016f7 563928eb
......@@ -88,20 +88,6 @@
CCCF85EB83511B97EF23244B /* Pods_OCR_SDK.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B6D65EE1B3D4F09B622C686E /* Pods_OCR_SDK.framework */; };
/* End PBXBuildFile section */
/* Begin PBXCopyFilesBuildPhase section */
958D36C324C18BB1004B27EB /* Embed Frameworks */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = "";
dstSubfolderSpec = 10;
files = (
958D36C224C18BB1004B27EB /* Pods_OCR_SDK.framework in Embed Frameworks */,
);
name = "Embed Frameworks";
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */
2A440D461209C526DEA3FD58 /* Pods-OCR-SDK.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-OCR-SDK.debug.xcconfig"; path = "Target Support Files/Pods-OCR-SDK/Pods-OCR-SDK.debug.xcconfig"; sourceTree = "<group>"; };
3B6B0136F5F5B4ED2341A91B /* Pods_OCR_SDK.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_OCR_SDK.framework; sourceTree = BUILT_PRODUCTS_DIR; };
......@@ -493,7 +479,6 @@
955105732477746A0053036F /* Sources */,
955105742477746A0053036F /* Frameworks */,
955105752477746A0053036F /* Resources */,
958D36C324C18BB1004B27EB /* Embed Frameworks */,
);
buildRules = (
);
......
____SDK:
là một thư viện giúp hỗ trợ chạy phần xử lý A.I tại máy điện thoại giúp cải thiện tốc độ phản hồi cũng như chất lượng dịch vụ.
## Framework Suport
* Phát hiện khuôn mặt trong khung hình (01 khuôn mặt lớn nhất trong hình)
* Phát hiện khuôn mặt giả mạo
* Phát hiện Giấy tờ tuỳ thân giả mạo
* Phát hiện mặt Giấy tờ tuỳ thân (mặt trước/ sau)
- Version iOS - Presentation style (ngang, dọc)
* IOS : versionName "1.0".
- Version iOS - requirement
* IOS : minOS 11.0
- Interface - Example usage (Cái này em thấy có note interface đơn giản rồi)
- Permissions
+ Camera
+ INTERNET
+ android:usesCleartextTraffic="true"
+ IOS : NSAppTransportSecurity.
- Callback handler (Success/ Error/ Other exception)
* CMT front
+ Success => Take CMT back.
+ Fail => Try agin take CMT front.
* CMT back
+ Success => Preview guide.
+ Fail => Try again take CMT back.
* Preview screen.
+ Click proceed to take selfie => Take face.
* Face
+ Success => return result.
+ Fail => Take face.
- Customize (UI, flow) update in lib.
- 1 hình thể hiện các screen của sdk chạy (Screen 1 - Screen 2 - Screen 3 - vv)
## Import framework
import SB_KYC_SDK
## Use and result
let ocrConfig: [String: Any] = [
"language": "en", //en or vi
"url_font": "http://sdk.sb.gotai.ml/process_card_front",
"url_back": "http://sdk.sb.gotai.ml/process_card_back",
"url_face": "http://sdk.sb.gotai.ml/call/predict_front_back_face",
"type_face": "RECORD", //TAKEPHOTO or RECORD
"colorText": "#FFFFFF",
"colorBackgroundButtonNext": "#225F8D",
"colorBackgroundButtonBack": "#DBDBDD",
"colorTextButtonNext": "#FFFFFF",
"colorTextButtonBack": "#225F8D",
"colorTextPreview": "#FFFFFF",
"colorBackgroundButtonTutoriol": "",
"front": "",
"ratioPass": 50,
"copyright": "Copyright by ITSOL",
"step": "ALL",// ALL or STEP1
"useFileCer" : true,
"header": header,
]
let ocrSDK = SB_KYC_SDK.shared
ocrSDK.initSDK(viewCurrent: self, sdkConfig: ocrConfig){ [weak self] data,before,behide in
guard let `self` = self else { return }
DispatchQueue.main.async {
let show = showData()
show.before1 = before // anh mat truoc type: Data
show.behide1 = behide // anh mat sau type: Data
show.dataResult = data! // du lieu detect [String:Any]
self.navigationController?.pushViewController(show, animated: true)
}
}
## Create file .cer
Open terminal, run: openssl s_client -connect my-https-website.com:443 -showcerts < /dev/null | openssl x509 -outform DER > my-https-website.der
coppy file my-https-website.der into the folder FileSSL
## Build framework
- Open ios-sdk, run framwork
- coppy file SB_KYC_SDK.framework into your project
## Use method public:
- Validate card:
SB_KYC_SDK.shared.eKycCardValid(image: UIImge)
//output: Int, 0: Fake photo, 1: image front, 2: image card, -1: image error
- Validate face:
SB_KYC_SDK.shared.eKycFaceValid(image: UIImge){ [weak self] data in
guard let `self` = self else { return }
//error: ["error": errorCode]
//success: respone api
}
- call API facec:
SB_KYC_SDK.shared.eKycFaceMatch(imageFace: UIImge, imageCardFront: UIImge, imageCardBack: UIImge){ [weak self] data in
guard let `self` = self else { return }
//error: ["error": errorCode]
//success: respone api
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment