0

I have a cocoapod I've built which makes use of Apples new coreml library. As such it has several .mlmodel files that it makes use of to do data categorization etc.

The issue I am facing is that when I add the pod to another project and run a pod install it installs the pod as required, but the .mlmodel files are all missing - meaning the class files they generate are not found, so as such if I try to do a build, it fails. I know that .mlmodel files are a bit special as they are static files that generate a class on compilation, but I'm not sure how to force them to be included as files in the pod.

I have tried using smaller models in case it was a file size issue, ala the 100MB limit that git has for example, but this did not help. I'm not sure how to deal with it, as a static image file, for example, works fine.

Currently, I just manually drag the .mlmodel files into the pod folder after I've done an install, but this obviously is not a feasible method for build servers etc.

asked Jan 10, 2018 at 4:36
1
  • Show your pod file Please Commented Jan 10, 2018 at 4:42

1 Answer 1

1

Use preserve_paths in the podspec for the .mlmodel files.

answered Jan 10, 2018 at 17:07
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.