Tensor Dimensions Error - TensorFlowLiteTaskVision

Hi,
I am working with TensorFlowLiteTaskVision and a custom trained model, and I am getting this error:
Tensorflowlitetaskvision Output tensor at index 0 is expected to have 3 dimensions, found 2.

Searching it up online, I had saw that it was some issue with the new versions of tensorflow. How would I solve this in swift with Tensorflowlitetaskvision?

@kim,

Could you please provide on which versions of Tensorflow and TensorFlowLiteTaskVision the issue is ?

Thank you!

I’m not sure what version of Tensorflow it is (since I had downloaded TensorFlowLiteTaskVision only) , but I think TensorFlowLiteTaskVision is version 0.4.1 if the bundle string is to be believed.

It is the latest version from my knowledge.

@kim,

Add the TensorFlowLiteTaskVision pod in the Podfile.

target 'MyAppWithTaskAPI' do
   use_frameworks! 
   pod 'TensorFlowLiteTaskVision','~> 0.4.3'
end

Thank you!

Hi, thanks I tried this however I’m still getting the error.
I also tried checking the version of TensorFlowLiteTaskVision in the Pods page, but the info tab has disappeared. I only see “Resource Tags” “Build Settings” “Build Phases” “Build Rules” there now.
Is there anything else I can do?

@kim,

Since it is a bug, please create an issue on github for the fix.

Thank you!


My pod file ^


My targets ^

Oh, I see. Will do so.