Posts

Post not yet marked as solved
2 Replies
2.2k Views
I'm receiving this fatal exception in iOS 13 beta 1 when using my Core ML image classification modelMTLDebugValidateMTLPixelFormat, line 1388: error 'pixelFormat (11) is not a valid MTLPixelFormat.'MTLDebugValidateMTLPixelFormat:1388: failed assertion `pixelFormat (11) is not a valid MTLPixelFormat.' guard let drawingImage = canvasView.currentDrawing.rasterized()?.cgImage, let model = try? VNCoreMLModel(for: Symbols().model) else { return } let classificationRequest = VNCoreMLRequest(model: model) { [weak self] (request, error) in self?.processClassifications(for: request, error: error) } classificationRequest.imageCropAndScaleOption = .centerCrop let handler = VNImageRequestHandler(cgImage: drawingImage) try? handler.perform([classificationRequest]) //crashes here
Posted
by Jordan.
Last updated
.
Post not yet marked as solved
2 Replies
4.9k Views
In iOS 13 users can select their preferred language for your app in Settings. It appears this only shows up if your app supports more than one language and only lists the languages your app supports, which makes sense.I have a kind of unique situation in my app. It is not localized for any language except English, however the app allows users to work with dates formatted in their preferred language's format. This is currently implemented vialet dateFormatter = DateFormatter() dateFormatter.locale = Locale(identifier: Locale.preferredLanguages.first!) dateFormatter.calendar = .currentLocale.preferredLanguages lists the user's preferred languages as specified in Settings which satisfies most users. But some have requested I add a language selector in the app because sometimes they don't want to use their most preferred locale. So it sounded like the iOS 13 app-specific language selection would be great for me! But it seems that's not the case. Any suggestions on what would be best to do in this scenario?
Posted
by Jordan.
Last updated
.