これだとうまくいかない
$ gst-device-monitor-1.0
$ gst-launch-1.0 v4l2src device=/dev/video0 ! h264parse ! video/x-h264,stream-format=avc,alignment=au ! kvssink stream-name=MyKinesisVideoStream storage-size=128 access-key=”***” secret-key=”***” aws-region=”ap-northeast-1″
> The audio recording device is represented by hw:card_number,device_numer. So to use the second device in the example, use hw:3,0 as the device in gst-launch-1.0 command.
これだとOK
$ gst-launch-1.0 -v v4l2src device=/dev/video0 ! videoconvert ! video/x-raw,format=I420,width=640,height=480,framerate=30/1 ! x264enc bframes=0 key-int-max=45 bitrate=500 tune=zerolatency ! video/x-h264,stream-format=avc,alignment=au ! kvssink stream-name=MyKinesisVideoStream storage-size=128 access-key=”***” secret-key=”***” aws-region=”ap-northeast-1″
> if your camera supports outputting h264 encoded stream directly, then you can use this command:
$ python3 app.py
// 省略
FOUR SCORE AND SEVEN YEARS AGO OUR FATHERS BROUGHT FORTH ON THIS CONTINENT A NEW NATION CONCEIVED IN LIBERTY AND DEDICATED TO THE PROPOSITION THAT ALL MEN ARE CREATED EQUAL
なるほど、これは凄い
tokenizerとmodelを日本語でやりたい
from asrecognition import ASREngine
asr = ASREngine("ja", model_path="jonatasgrosman/wav2vec2-large-xlsr-53-japanese")
audio_paths = ["itou.wav"]
transcriptions = asr.transcribe(audio_paths)
$ python3 app.py
/home/vagrant/.local/lib/python3.8/site-packages/transformers/configuration_utils.py:340: UserWarning: Passing `gradient_checkpointing` to a config initialization is deprecated and will be removed in v5 Transformers. Using `model.gradient_checkpointing_enable()` instead, or if you are using the `Trainer` API, pass `gradient_checkpointing=True` in your `TrainingArguments`.
warnings.warn(
Killed