diegoalejogm / gans

Generative Adversarial Networks implemented in PyTorch and Tensorflow
MIT License
832 stars 353 forks source link

AttributeError: 'function' object has no attribute 'Variable' #4

Closed buncis closed 5 years ago

buncis commented 6 years ago

when trying to run 1. Vanilla GAN PyTorch.ipynb on my laptop I got this error

---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<ipython-input-69-81fdb6b15e61> in <module>()
     19         g_error = train_generator(g_optimizer, fake_data)
     20         # Log error
---> 21         logger.log(d_error, g_error, epoch, n_batch, num_batches)
     22 
     23         # Display Progress

~/gans/utils.py in log(self, d_error, g_error, epoch, n_batch, num_batches)

AttributeError: 'function' object has no attribute 'Variable'
hallofire commented 6 years ago

Same Problem here

screen shot 2018-08-25 at 13 25 40
economy commented 6 years ago

See my edits here: https://github.com/diegoalejogm/gans/pull/5

diegoalejogm commented 5 years ago

Fixed as proposed by @economy