kaldi-active-grammar icon indicating copy to clipboard operation
kaldi-active-grammar copied to clipboard

unable to install on Mac OS 12.3.1

Open droundy opened this issue 2 years ago • 7 comments

I am unable to install kaldi-active-grammar on macOS Monterey version 12.3.1.

My Python is 3.8.9, and pip install kaldi-active-grammar fails with an error message "No matching distribution found for kaldi-active-grammar".

When I download the release wheel for macOS, I am told that it is not a supported wheel on this platform.

Any suggestions? Or do you just need to build another wheel? I notice the download is labeled macos_10_9 so maybe it's for too old a macOS?

droundy avatar Apr 25 '22 12:04 droundy

Looks like the issue may be that I have an m1 Mac with an arm cpu?

droundy avatar Apr 26 '22 17:04 droundy

I'm also seeing this problem. M1 Mac as well.

denvaar avatar Aug 06 '22 06:08 denvaar

@droundy have you found a way around it? I've been trying to build from source, but running into a lot of issues.

denvaar avatar Aug 08 '22 14:08 denvaar

No, I have not.

droundy avatar Aug 08 '22 21:08 droundy

@droundy after a lot of tweaking and trial and error I was finally able to build from source and create a wheel that I can use with Dragonfly. I can try to come up with some instructions if you're interested, though it may be pretty hacky.

denvaar avatar Aug 11 '22 17:08 denvaar

@denvaar Hi there! I would be happy if you could provide some kind of instruction for building this project on Macbook M1.

I've been trying to build the project wheel for a few days to no avail, your instructions would help a lot.

Thank you! ❤️

bogdan0083 avatar Sep 20 '22 12:09 bogdan0083

I finally managed to build kaldi-active-grammar on Mac M1. Here's PR: https://github.com/daanzu/kaldi-active-grammar/pull/75. It's not merged yet but you can already try to clone that branch from my fork, remove SOURCE_DIR, BUILD_DIR, DOWNLOAD_DIR and add the following changes to the file CMakeLists.txt:

Снимок экрана 2023-01-28 в 15 18 56

This temporary fix will use my kaldi fork instead of David's. Then use can use

python setup.py bdist_wheel

and the wheel will be installed in the dist folder. Now you can install the built .whl file as a pip package.

In case you're stuck or something is not working you can ask a question here, I'd be happy to help.

bogdan0083 avatar Jan 28 '23 08:01 bogdan0083