Machine Learning in iOS · Vision |

This is a companion discussion topic for the original entry at

I’m having trouble building the sample project for this lesson. The .mlmodel file isn’t found, resulting in a compiler error.

I’ve tried to delete & re-add the file in the project’s Build Phases, but for some reason xcode adds the file in the .. project path, while the .swift files are correctly added as in the Snacks path.


error: Build input file cannot be found: '/Users/ben/_dev/rw-dls/3 - Vision/End/HealthySnacks.mlmodel' (in target 'HealthySnacks' from project 'Snacks')

1 Like

Thanks for letting us know! I updated the materials.

Thanks, can confirm that made the difference.

Could you explain what fixed it? I tried to move the file around, and remove/re-add it to the project, but wasn’t able to straighten it out.

The location of the file was incorrect. I just went to the File Inspector and selected where it actually was, in Finder. As to how it was wrong in the first place (when you can clearly see that it worked when I recorded this), and why nobody else mentioned it, I have no idea!

1 Like