mirror of
https://github.com/DarthAffe/StableDiffusion.NET.git
synced 2025-12-12 13:28:35 +00:00
37 lines
973 B
C#
37 lines
973 B
C#
using JetBrains.Annotations;
|
|
|
|
namespace StableDiffusion.NET;
|
|
|
|
[PublicAPI]
|
|
public sealed class StableDiffusion3_5ModelBuilder : IDiffusionModelBuilder, IQuantizedModelBuilder
|
|
{
|
|
#region Properties & Fields
|
|
|
|
public DiffusionModelParameter Parameter { get; }
|
|
IDiffusionModelParameter IDiffusionModelBuilder.Parameter => Parameter;
|
|
IQuantizedModelParameter IQuantizedModelBuilder.Parameter => Parameter;
|
|
|
|
#endregion
|
|
|
|
#region Constructors
|
|
|
|
public StableDiffusion3_5ModelBuilder(string modelPath, string clipLPath, string clipGPath, string t5xxlPath)
|
|
{
|
|
Parameter = new DiffusionModelParameter
|
|
{
|
|
DiffusionModelType = DiffusionModelType.StableDiffusion,
|
|
ModelPath = modelPath,
|
|
ClipLPath = clipLPath,
|
|
ClipGPath = clipGPath,
|
|
T5xxlPath = t5xxlPath,
|
|
};
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region Methods
|
|
|
|
public DiffusionModel Build() => new(Parameter);
|
|
|
|
#endregion
|
|
} |