Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to load _MLModelProxy: No module named 'coremltools.libcoremlpython #2220

Closed
Asadashino-o opened this issue May 16, 2024 · 3 comments
Closed
Labels
question Response providing clarification needed. Will not be assigned to a release. (type)

Comments

@Asadashino-o
Copy link

I use "pip install -U coremltools" to download the package

pip show coremltools
Name: coremltools
Version: 7.2
Summary: Community Tools for Core ML
Home-page: https://github.com/apple/coremltools
Author: Apple Inc.
Author-email: coremltools@apple.com
License: BSD
Location: /data/hdd1/miniconda3/envs/det/lib/python3.9/site-packages
Requires: attrs, cattrs, numpy, packaging, protobuf, pyaml, sympy, tqdm
Required-by: onnx-coreml

but when I use:
python
import coremltools as ct

Error:Failed to load _MLModelProxy: No module named 'coremltools.libcoremlpython

@Asadashino-o Asadashino-o added the question Response providing clarification needed. Will not be assigned to a release. (type) label May 16, 2024
@YifanShenSZ
Copy link
Collaborator

Hi @Asadashino-o, could you please try to pip install coremltools in a clean environment?

@Asadashino-o
Copy link
Author

Asadashino-o commented May 21, 2024

Hi @Asadashino-o, could you please try to pip install coremltools in a clean environment?

Thanks for your suggestion! However I get knowledge from my classmates, it may cause some errors in Linux ? (He told me that he once encountered problems while using Coremltools7+on Linux and successfully ran it on MacOS) That’s why?

Also, does Coremltools7+no longer support converting ONNX to Coreml?

@YifanShenSZ
Copy link
Collaborator

encountered problems while using Coremltools7+on Linux and successfully ran it on MacOS

Yes that could be the case. The Core ML framework is part of MacOS, so any functionality depending on Core ML framework can only run on MacOS. AFAIK, on Linux we only guarantee conversion and serialization of models.

Also, does Coremltools7+no longer support converting ONNX to Coreml?

Let's continue our ONNX->CoreML discussion in #2225

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Response providing clarification needed. Will not be assigned to a release. (type)
Projects
None yet
Development

No branches or pull requests

2 participants