exPHAT / SwiftWhisper

🎤 The easiest way to transcribe audio in Swift
MIT License
580 stars 61 forks source link

watchOS support? #23

Closed haozes closed 1 year ago

haozes commented 1 year ago

Need watchOS support.

Best Regards

exPHAT commented 1 year ago

The watch surely doesn't meet the memory or processor requirements of these models.

haozes commented 1 year ago

Apple Watch 7 + series have 1GB+ RAM , It's enough to run whisper tiny model. and I tried it, it works. The only problem is the process, the transcribe time is too long (10 seconds wav need 6 sec on my Apple Watch Ultra) Maybe supporting ANE / CoreML can reduce the time to 2-3 seconds.

exPHAT commented 1 year ago

If you want to try, CoreML is supported. Though I don't think any of the watches have ANE.

haozes commented 1 year ago

If you want to try, CoreML is supported. Though I don't think any of the watches have ANE. As this document says: https://support.apple.com/en-il/HT213848

Apple Neural Engine Available for: Apple Watch Series 4 and later

Not so much information about ANE on watch, and I wil check it.

haozes commented 1 year ago

Hi, me again.

As I test by code: https://developer.apple.com/documentation/coreml/mlcomputedevice/4134993-allcomputedevices

MLComputeDevice.allComputeDevices

That's cool, print on my ultra watch, it has 1 neuralEngine , and 2 GPU.

exPHAT commented 1 year ago

I'll fix the watchOS build and you can feel free to try running it.

exPHAT commented 1 year ago

watchOS build working in latest 1.2.0 release. Feel free to try now if you want to make something with it.