yum-archive/TaSTT-Whisper

High-performance GPGPU inference of OpenAI's Whisper automatic speech recognition (ASR) model

git clone https://git.yummers.dev/yum-archive/TaSTT-Whisper

KonstantinSource codes8c4603c

master
854 B24 linesraw
1using Whisper.Internal;
2
3namespace Whisper
4{
5	/// <summary>Identifiers for an audio capture device</summary>
6	public record struct CaptureDeviceId
7	{
8		/// <summary>The display name is suitable for showing to the user, but might not be unique.</summary>
9		public string displayName;
10
11		/// <summary>Endpoint ID for an audio capture device.<br/>
12		/// It uniquely identifies the device on the system, but is not a readable string.</summary>
13		public string endpoint;
14
15		internal CaptureDeviceId( in sCaptureDevice rsi )
16		{
17			displayName = rsi.displayName ?? "<display name unavailable>";
18			endpoint = rsi.endpoint ?? throw new ApplicationException( "The device has no endpoint ID" );
19		}
20
21		/// <summary>Returns a String which represents the object instance</summary>
22		public override string ToString() => $"Capture device: \"{displayName}\"";
23	}
24}