fix(example/neural-style-transfer): save image
This commit is contained in:
parent
8fc6efca1c
commit
a0653fe4d3
|
@ -175,7 +175,7 @@ func main() {
|
|||
if (stepIdx % 1000) == 0 {
|
||||
clone := inputVar.MustShallowClone()
|
||||
img := clone.MustDetach()
|
||||
imageTs := img.MustTo(device, true)
|
||||
imageTs := img.MustTo(gotch.CPU, true)
|
||||
clone.MustDrop()
|
||||
err := in.SaveImage(imageTs, fmt.Sprintf("../../data/neural-style-transfer/out%v.jpg", stepIdx))
|
||||
if err != nil {
|
||||
|
|
Loading…
Reference in New Issue
Block a user