Skip to content

Instantly share code, notes, and snippets.

@angelovescio
angelovescio / pyaudio_to_deepspeech.py
Created February 18, 2022 01:54
Pump streaming audio to deepspeech
# download the pyaudio from https://github.com/intxcc/pyaudio_portaudio
import deepspeech
import numpy as np
import os
import pyaudio
import time
import samplerate as sr
import nnresample
from scipy import signal,io
@angelovescio
angelovescio / gist:84551fa3e9a49df2f036
Last active May 10, 2017 14:41
C# NTFS EA Example
[StructLayout(LayoutKind.Sequential, Pack = 0)]
public struct IO_STATUS_BLOCK
{
public uint status;
public IntPtr information;
}
[DllImport("ntdll.dll", ExactSpelling = true)]
public static extern uint NtQueryEaFile(
SafeFileHandle handle,
out IO_STATUS_BLOCK ioStatus,