Skip to content

Commit 221748c

Browse files
committed
Supertonic configuration
1 parent bfcb3ad commit 221748c

File tree

4 files changed

+86
-0
lines changed

4 files changed

+86
-0
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
using TensorStack.Common;
2+
3+
namespace TensorStack.TextGeneration.Pipelines.Supertonic
4+
{
5+
public record SupertonicConfig
6+
{
7+
public int SampleRate { get; init; } = 44100;
8+
public int BaseChunkSize { get; init; } = 512;
9+
public int LatentDim { get; init; } = 24;
10+
public int ChunkCompressFactor { get; init; } = 6;
11+
public int TextEmbedSize { get; init; } = 256;
12+
public int ScaleFactor { get; init; } = 3072;
13+
public string IndexerPath { get; init; }
14+
public string VoiceStylePath { get; init; }
15+
public ModelConfig PredictorConfig { get; init; }
16+
public ModelConfig EncoderConfig { get; init; }
17+
public ModelConfig EstimatorConfig { get; init; }
18+
public ModelConfig DecoderConfig { get; init; }
19+
}
20+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
using TensorStack.Common.Pipeline;
2+
3+
namespace TensorStack.TextGeneration.Pipelines.Supertonic
4+
{
5+
public record SupertonicOptions : IRunOptions
6+
{
7+
public string TextInput { get; set; }
8+
public string VoiceStyle { get; set; }
9+
public int Steps { get; set; } = 5;
10+
public float Speed { get; set; } = 1f;
11+
public float SilenceDuration { get; set; } = 0.3f;
12+
}
13+
}
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
using System;
2+
using System.Threading;
3+
using System.Threading.Tasks;
4+
using TensorStack.Common.Pipeline;
5+
using TensorStack.Common.Tensor;
6+
using TensorStack.TextGeneration.Common;
7+
8+
namespace TensorStack.TextGeneration.Pipelines.Supertonic
9+
{
10+
public class SupertonicPipeline : IPipeline<AudioTensor, SupertonicOptions, GenerateProgress>
11+
{
12+
public Task LoadAsync(CancellationToken cancellationToken = default)
13+
{
14+
throw new NotImplementedException();
15+
}
16+
17+
18+
public Task UnloadAsync(CancellationToken cancellationToken = default)
19+
{
20+
throw new NotImplementedException();
21+
}
22+
23+
24+
public Task<AudioTensor> RunAsync(SupertonicOptions options, IProgress<GenerateProgress> progressCallback = null, CancellationToken cancellationToken = default)
25+
{
26+
throw new NotImplementedException();
27+
}
28+
29+
30+
public void Dispose()
31+
{
32+
throw new NotImplementedException();
33+
}
34+
}
35+
}
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
using TensorStack.Common.Tensor;
2+
3+
namespace TensorStack.TextGeneration.Pipelines.Supertonic
4+
{
5+
public record VoiceStyle
6+
{
7+
public VoiceStyle(string name, Tensor<float> global, Tensor<float> dropout)
8+
{
9+
Name = name;
10+
Global = global;
11+
Dropout = dropout;
12+
}
13+
14+
public string Name { get; init; }
15+
public Tensor<float> Global { get; init; }
16+
public Tensor<float> Dropout { get; init; }
17+
}
18+
}

0 commit comments

Comments
 (0)