CuriousAI / tagger

Deep Unsupervised Perceptual Grouping
BSD 3-Clause "New" or "Revised" License
131 stars 34 forks source link

I have some running problems #2

Open zzujw7 opened 7 years ago

zzujw7 commented 7 years ago

I am a student, I recently run your program but there was a mistake, I personally think that my version of the machine environment and you are some different, can you run the version of the environment tell me. Then I put the results of the operation paste, I think the last line is the key to the problem.

thank you!

Building graphs Traceback (most recent call last): File "runner-shapes50k20x20.py", line 25, in experiment = TaggerExperiment(p) File "/home/jw/git_workspace/tagger/tagger/tagger_exp.py", line 29, in init self.tagger = Tagger.create_tagger(self.p) File "/home/jw/git_workspace/tagger/tagger/tagger.py", line 36, in create_tagger tagger.apply() File "/home/jw/git_workspace/tagger/tagger/tagger.py", line 128, in apply self.clean.update(self.apply_tagger(x_only, False)) File "/home/jw/git_workspace/tagger/tagger/tagger.py", line 303, in apply_tagger ami_score, ami_score_per_sample = self.mask_accuracy(self.masks_unlabeled, m_hat) File "/home/jw/git_workspace/tagger/tagger/tagger.py", line 439, in mask_accuracy ami_score_per_sample = ami_score_op(mask_true[0], mask_est) File "/home/jw/.conda/envs/tagger/lib/python2.7/site-packages/theano/gof/op.py", line 611, in call node = self.make_node(*inputs, **kwargs) File "/home/jw/.conda/envs/tagger/lib/python2.7/site-packages/theano/gof/op.py", line 993, in make_node (str([inp.type for inp in inputs]), str(self.itypes))) TypeError: We expected inputs of types '[TensorType(float32, 3D), TensorType(float64, 3D)]' but got types '[TensorType(float32, 3D), TensorType(float32, 3D)]'

adamluo1995 commented 7 years ago

I have this problem too.

Qwlouse commented 7 years ago

Hi, sounds like a theano problem with float64. Do you have a .theanorc file in your home with this?

[global]
warn_float64 = raise
floatX = float32
scientist1642 commented 7 years ago

Adding .theanorc solved it for me. Thanks!

zxiaomzxm commented 7 years ago

Switch config.floatX to float32. import theano theano.config.floatX = 'float32'