saddam213 commited on
Commit
3437949
1 Parent(s): e0d906c

Upload 6 files

Browse files
Files changed (6) hide show
  1. .gitattributes +1 -0
  2. README.md +34 -37
  3. Sample.png +2 -2
  4. Sample1.png +3 -0
  5. Sample2.png +2 -2
  6. Sample3.png +2 -2
.gitattributes CHANGED
@@ -39,3 +39,4 @@ Sample.png filter=lfs diff=lfs merge=lfs -text
39
  Sample2.png filter=lfs diff=lfs merge=lfs -text
40
  Sample3.png filter=lfs diff=lfs merge=lfs -text
41
  Sample4.png filter=lfs diff=lfs merge=lfs -text
 
 
39
  Sample2.png filter=lfs diff=lfs merge=lfs -text
40
  Sample3.png filter=lfs diff=lfs merge=lfs -text
41
  Sample4.png filter=lfs diff=lfs merge=lfs -text
42
+ Sample1.png filter=lfs diff=lfs merge=lfs -text
README.md CHANGED
@@ -1,38 +1,35 @@
1
- ---
2
- pipeline_tag: text-to-image
3
- ---
4
- # SDXL Lightning - Onnx Olive DirectML Optimized
5
-
6
- ## Original Model
7
- https://huggingface.co/ByteDance/SDXL-Lightning
8
-
9
- ## C# Inference Demo
10
- https://github.com/saddam213/OnnxStack
11
-
12
- ```csharp
13
- // Create Pipeline
14
- var pipeline = StableDiffusionXLPipeline.CreatePipeline("D:\\Repositories\\SDXL-Lightning-onnx");
15
-
16
- // Prompt
17
- var promptOptions = new PromptOptions
18
- {
19
- Prompt = "photo of a cat drinking at a bar"
20
- };
21
-
22
- // Scheduler Options
23
- var schedulerOptions = pipeline.DefaultSchedulerOptions with
24
- {
25
- SchedulerType = SchedulerType.Euler,
26
- InferenceSteps = 8,
27
- GuidanceScale = 0,
28
- BetaSchedule = BetaScheduleType.Linear
29
- };
30
-
31
- // Run pipeline
32
- var result = await pipeline.GenerateImageAsync(promptOptions, schedulerOptions);
33
-
34
- // Save Image Result
35
- await result.SaveAsync("Result.png");
36
- ```
37
- ## Inference Result
38
  ![Intro Image](Sample.png)
 
1
+ # SDXL Lightning - Onnx Olive DirectML Optimized
2
+
3
+ ## Original Model
4
+ https://huggingface.co/ByteDance/SDXL-Lightning
5
+
6
+ ## C# Inference Demo
7
+ https://github.com/saddam213/OnnxStack
8
+
9
+ ```csharp
10
+ // Create Pipeline
11
+ var pipeline = StableDiffusionXLPipeline.CreatePipeline("D:\\Repositories\\SDXL-Lightning-onnx");
12
+
13
+ // Prompt
14
+ var promptOptions = new PromptOptions
15
+ {
16
+ Prompt = "Craft an image of a galaxy far, far away, with swirling nebulae and distant stars painting the cosmic canvas"
17
+ };
18
+
19
+ // Scheduler Options
20
+ var schedulerOptions = pipeline.DefaultSchedulerOptions with
21
+ {
22
+ SchedulerType = SchedulerType.Euler,
23
+ InferenceSteps = 8,
24
+ GuidanceScale = 0,
25
+ BetaSchedule = BetaScheduleType.Linear
26
+ };
27
+
28
+ // Run pipeline
29
+ var result = await pipeline.GenerateImageAsync(promptOptions, schedulerOptions);
30
+
31
+ // Save Image Result
32
+ await result.SaveAsync("Result.png");
33
+ ```
34
+ ## Inference Result
 
 
 
35
  ![Intro Image](Sample.png)
Sample.png CHANGED

Git LFS Details

  • SHA256: 0b06ee552b7751e544a8a36420d338edc1145cf78d8e978ba3a0a90bbf51b6f2
  • Pointer size: 132 Bytes
  • Size of remote file: 1.67 MB

Git LFS Details

  • SHA256: cde0e5ce081c2c5cfe3c84ad82124cdd93575b9244625a79c1c4313d13c3226c
  • Pointer size: 132 Bytes
  • Size of remote file: 1.86 MB
Sample1.png ADDED

Git LFS Details

  • SHA256: ae28ed1ec8166a441844f343e3818caccbb39e26b1de78bfc5bf4406aa06d7f8
  • Pointer size: 132 Bytes
  • Size of remote file: 1.92 MB
Sample2.png CHANGED

Git LFS Details

  • SHA256: d01ac5297f28e9a66b3c3d46f6493d11b35875c6e45bc36e9d9b2ea1ad3803e8
  • Pointer size: 132 Bytes
  • Size of remote file: 1.65 MB

Git LFS Details

  • SHA256: 57bf9106f87d2355a72e0a3aaf72bd2c901c6b62e50d4188b2cb766aa7d9a29b
  • Pointer size: 132 Bytes
  • Size of remote file: 1.8 MB
Sample3.png CHANGED

Git LFS Details

  • SHA256: 18b44a980c257f1b3a91d24fb504f6b92072430f1ec06ecab94fefa25c5ee2d9
  • Pointer size: 132 Bytes
  • Size of remote file: 1.67 MB

Git LFS Details

  • SHA256: 43ad3b284b0ddfbb0b29fbc62ca2c5408e61c90f8197b9f37b74d9b8be5e228d
  • Pointer size: 132 Bytes
  • Size of remote file: 1.66 MB