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

fix: model path encoding in windows #2086

Merged
merged 3 commits into from May 14, 2024

Conversation

thewh1teagle
Copy link
Contributor

Resolve #2052 by using wide char.

By the way, examples/main.cpp also have problem when reading model path / wav path from argv in Windows.
Maybe it's due to invalid console encoding, I tried to enable SetConsoleOutputCP(CP_UTF8) and it didn't helped in main example.

@ggerganov
Copy link
Owner

@tamo
Copy link
Contributor

tamo commented May 9, 2024

Maybe we can use _MSC_VER instead of _WIN32 here because wide string in ifstream is MSVC extension. _WIN32 affects all compilers including gcc and llvm.

@thewh1teagle
Copy link
Contributor Author

@ggerganov ggerganov merged commit d8356a1 into ggerganov:master May 14, 2024
48 of 49 checks passed
bygreencn added a commit to bygreencn/whisper.cpp that referenced this pull request May 14, 2024
* ggerganov/master: (291 commits)
  whisper : fix model path encoding in windows (ggerganov#2086)
  server : return utf-8 (ggerganov#2138)
  node : add audio_ctx and audio buffer params (ggerganov#2123)
  cmake : fix HIP/ROCm build (ggerganov#2102)
  node : add additional params (ggerganov#2000)
  js : remove un-needed request header from fetchRemote (ggerganov#2119)
  cmake : fix metal embed sources path (ggerganov#2110)
  main : dont print timings with --no-prints (ggerganov#2108)
  main : add options for temperature control (ggerganov#2088)
  whisper : switch back to F32 mask (#0)
  whisper.android : update example, add field to print timestamp (ggerganov#2072)
  cmake : fix json INTERFACE library (ggerganov#2069)
  main : fix double quote escaping in csv output (ggerganov#2090)
  metal : tune soft_max number of threads (#0)
  whisper : remove old flash attn code (#0)
  ggml : try fix ppc64 (#0)
  ggml : remove oboslete alibi code (skipme) (#0)
  talk-llama : sync llama.cpp
  sync : ggml
  ggml : optimize for ppc64le using VSX intrinsics (ggml/784)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Model fail to load if path contains Hebrew characters
3 participants