projects
/
pytorch.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
72584ec
)
Update.
author
Francois Fleuret
<francois@fleuret.org>
Sun, 14 Aug 2022 18:55:35 +0000
(20:55 +0200)
committer
Francois Fleuret
<francois@fleuret.org>
Sun, 14 Aug 2022 18:55:35 +0000
(20:55 +0200)
minidiffusion.py
patch
|
blob
|
history
diff --git
a/minidiffusion.py
b/minidiffusion.py
index
841dd2a
..
65ca947
100755
(executable)
--- a/
minidiffusion.py
+++ b/
minidiffusion.py
@@
-269,6
+269,7
@@
if train_input.dim() == 2:
fig = plt.figure()
ax = fig.add_subplot(1, 1, 1)
fig = plt.figure()
ax = fig.add_subplot(1, 1, 1)
+ # Nx1 -> histogram
if train_input.size(1) == 1:
x = generate((10000, 1), alpha, alpha_bar, sigma,
if train_input.size(1) == 1:
x = generate((10000, 1), alpha, alpha_bar, sigma,
@@
-290,6
+291,7
@@
if train_input.dim() == 2:
ax.legend(frameon = False, loc = 2)
ax.legend(frameon = False, loc = 2)
+ # Nx2 -> scatter plot
elif train_input.size(1) == 2:
x = generate((1000, 2), alpha, alpha_bar, sigma,
elif train_input.size(1) == 2:
x = generate((1000, 2), alpha, alpha_bar, sigma,
@@
-319,6
+321,7
@@
if train_input.dim() == 2:
plt.get_current_fig_manager().window.setGeometry(2, 2, 1024, 768)
plt.show()
plt.get_current_fig_manager().window.setGeometry(2, 2, 1024, 768)
plt.show()
+# NxCxHxW -> image
elif train_input.dim() == 4:
x = generate((128,) + train_input.size()[1:], alpha, alpha_bar, sigma,
elif train_input.dim() == 4:
x = generate((128,) + train_input.size()[1:], alpha, alpha_bar, sigma,