Skip to content

AttributeError: module 'tensorflow' has no attribute 'placeholder_with_default' #52

@a0wsxz9

Description

@a0wsxz9

Hello,there was a issue when I tried running the example.
DTQ:

Traceback (most recent call last):
File "train_val_script.py", line 74, in
model_weights = model.train(train_img, database_img, query_img, args)
File "C:\DeepHash-master\DeepHash-master\DeepHash\model\dtq_init_.py", line 5, in train
model = DTQ(config)
File "C:\DeepHash-master\DeepHash-master\DeepHash\model\dtq\dtq.py", line 24, in init
self.stage = tf.placeholder_with_default(tf.constant(0), [])
AttributeError: module 'tensorflow' has no attribute 'placeholder_with_default'

DCH:

Traceback (most recent call last):
File "train_val_script.py", line 61, in
model_weights = model.train(train_img, database_img, query_img, args)
File "C:\DeepHash-master\DeepHash-master\DeepHash\model\dch_init_.py", line 5, in train
model = DCH(config)
File "C:\DeepHash-master\DeepHash-master\DeepHash\model\dch\dch.py", line 29, in init
self.stage = tf.placeholder_with_default(tf.constant(0), [])
AttributeError: module 'tensorflow' has no attribute 'placeholder_with_default'

Is it because of my tensorflow's version?

And another thing,can I get the intermediate hash value from the model? I'm studying the secure scheme of image retrieve based on hash of hamming space.I want to use these models to make sure the precision, but I don't know if I could.I'd appreciate some help!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions