]> git.djapps.eu Git - pkg/ggml/sources/whisper.cpp/commit
ruby : transcribe without GVL, accept more MemoryViews, Windows support, fix memory...
authorKITAITI Makoto <redacted>
Thu, 7 May 2026 04:28:18 +0000 (13:28 +0900)
committerGitHub <redacted>
Thu, 7 May 2026 04:28:18 +0000 (06:28 +0200)
commitc81b2dabbc45484dee2ca6658cfe39c841df5c70
treef871c40d3fb417fd7c329dba5dc70fd4b746e082
parent4bf733672b2871d4153158af4f621a6dd9104f4a
ruby : transcribe without GVL, accept more MemoryViews, Windows support, fix memory size report, improve document (#3775)

* Change MemoryView example using NDAV

* Add note on audio attributes for #full and #full_parallel

* Support more variants of MemoryView

* Use IO.popen instead of Kernel.` for Windows compatibility

* Use cmake's -C option instead of multiple -D options

* Fix memsize calculation

* Remove unused argument

* Add is_interrupted field to abort callback container

* Fix RBS syntax

* Address document comment for RDoc

* Add .document for RDoc

* Add .rdoc_options

* Run #full without GVL

* Initialize callbacks with nil

* Specify implicity Whisper::Params to distinguish from Whisper::Context::Params

* Run callbacks without GVL

* Call log callback with GVL

* Run full_parallel without GVL

* Run transcribe without GVL

* Fix ruby_whisper_lock_gvl and ruby_whisper_unlock_gvl

* Fix return value of encoder_begin_callback

* Report GVL unlocking from transcribe

* Remove unused interface

* Restore overload of full_parallel

* Close process

* Fix struct name

* Make is_without_gvl thread local

* Use rb_thread_call_with_gvl instead of global variable

* Retrieve instance variable in GVL

* Narrow acceptable MemoryView format

* Fix option cache path

* Reduce files in package

* Use append_cflags

* Add ext/*.rb to task dependencies

* Use copy instead of cp

* Make TestPackage more portable

* Patch for lower version Ruby

* Make build scripts more portable

* Add Windows support

* Don't raise exceptions
17 files changed:
bindings/ruby/.document [new file with mode: 0644]
bindings/ruby/.rdoc_options [new file with mode: 0644]
bindings/ruby/README.md
bindings/ruby/Rakefile
bindings/ruby/ext/dependencies.rb
bindings/ruby/ext/dependencies_for_windows.rb [new file with mode: 0644]
bindings/ruby/ext/extconf.rb
bindings/ruby/ext/options.rb
bindings/ruby/ext/options_for_windows.rb [new file with mode: 0644]
bindings/ruby/ext/ruby_whisper.c
bindings/ruby/ext/ruby_whisper.h
bindings/ruby/ext/ruby_whisper_context.c
bindings/ruby/ext/ruby_whisper_params.c
bindings/ruby/ext/ruby_whisper_transcribe.cpp
bindings/ruby/extsources.rb
bindings/ruby/sig/whisper.rbs
bindings/ruby/test/test_package.rb