validateComputeFunctionArguments:817: failed assertion `Compute Function(mainMetalEntryPoint): Non-writeable texture format MTLPixelFormatBGRA8Unorm_sRGB is being bound at index 0 to a shader argument with write access enabled.'
CIImage *ciImage = [[CIImage alloc] initWithImage: img];
VNImageRequestHandler* handler = [[VNImageRequestHandler alloc]
initWithCIImage:ciImage
orientation:(CGImagePropertyOrientation)img.imageOrientation
options:@{}];
VNDetectFaceRectanglesRequest* request = [[VNDetectFaceRectanglesRequest alloc] initWithCompletionHandler:^(VNRequest * _Nonnull request, NSError * _Nullable error) {
...
}];
NSError *error;
//This is throwing the error
[handler performRequests:@[request] error:&error];
This works fine in 12