Comments (18)
no,though it is empty,it also can use without error.
from stegastamp.
I am a bit confused by your questions.
When you run bash scripts/base.sh EXP_NAME
does it not save out the model?
from stegastamp.
from stegastamp.
Hi gslxr, i have the same proble. Did you solved it?
from stegastamp.
At the end of the training the model is saved here -
Line 216 in de4e8ca
Can you verify this line is run without error, if not, what is the error? Perhaps there is permission issues with your folders?
from stegastamp.
Yes, that line runs without problem. the problem is that my saved_model.pb has a size of 215.5 MB and your saved_model.pb is 241.8kb. Also my variables folder is empty. and your traned model has two files of 217 MB and 2.4kb.
from stegastamp.
Ahh, gotcha. What happens when you try to run your saved model? What error do you get?
from stegastamp.
I got this
https://drive.google.com/file/d/1hHtizPeY8f4Spfkuahb8X2xZl_mt9-dy/view?usp=sharing this is the link of my trained model. I just change the size of the data to 50 bits.
Traceback (most recent call last): File "encode_image.py", line 93, in <module> main() File "encode_image.py", line 76, in main hidden_img, residual = sess.run([output_stegastamp, output_residual],feed_dict=feed_dict) File "/home/ed/Desktop/StegaStamp/virtualenv/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 956, in run run_metadata_ptr) File "/home/ed/Desktop/StegaStamp/virtualenv/lib/python3.7/site-packages/tensorflow_core/python/client/session.py", line 1156, in _run (np_val.shape, subfeed_t.name, str(subfeed_t.get_shape()))) ValueError: Cannot feed value of shape (1, 100) for Tensor 'input_prep:0', which has shape '(?, 50)'
from stegastamp.
You are getting a shape error
Cannot feed value of shape (1, 100) for Tensor 'input_prep:0', which has shape '(?, 50)'
This isn't caused by the saved model issue you mentioned above. You need to pass your secret size as an argument to encode image
.
Line 22 in de4e8ca
from stegastamp.
Yes! i understand that part.
python encode_image.py saved_models2/stegastamp_pretrained --image original.jpg --save_dir out/ --secret 12 --secret_size 50
This is the line i use. even if i write --secret_size 50 with your trained model. it does not show any error. where is the secret_size value used?
from stegastamp.
Ahh, yes that is an error on my part. Then encode_image.py
requires the code to be of length 100. This function uses BCH codes with specific parameters to convert a string into a 100bit message. You must use a different error correcting code (or no error correcting) if you change the size of the message.
from stegastamp.
Could you share a explample of encode and decode without error correcting code?. Please.
from stegastamp.
I'm not going to be able to write out a full example, but I can give some pointers.
For encoding, just change packet_binary
to the 50 bit binary code you want to store. You can ignore all of the previous lines regarding BCH.
Line 59 in 8e4eeda
For decoding,
Line 49 in 8e4eeda
secret
will contain your 50 bit message. All lines after can be ignored.
Also given that this is unrelated to the original issue, please create new issues for followup questions.
from stegastamp.
Thanks! I understand, I saw an example with a image encoded with 50 bits. So i tought you had an example.
from stegastamp.
no,though it is empty,it also can use without error.
Hi,gslxr,I also had this problem“ValueError: Cannot feed value of shape (1, 100) for Tensor 'input_prep:0', which has shape '(?, 20)'”,how did you solve it?
from stegastamp.
from stegastamp.
from stegastamp.
from stegastamp.
Related Issues (20)
- The encoded image can only be 400*400? HOT 4
- Which parameter or loss is the most important for the decodability of the printed image?
- How to convert encoded_image from tensor to numpy ? HOT 2
- Problem with parameter
- according to bash scripts/base.sh EXP_NAME,Model test after training HOT 5
- How to fine tune the model?
- Is the loss of the discriminator negative?
- How could I transform my picture like what displayed in the paper?
- what does the Cos dropoff means?
- How to train the model on 256x256?
- Secret Loss is not being optimized HOT 2
- How to embed url into imgs? HOT 1
- dataset HOT 1
- Can you provide the dataset you use?
- Questions about the tensorflow version HOT 3
- ValueError: The first layer in a Sequential model must get an `input_shape` or `batch_input_shape` argument. HOT 1
- Can't download trained models HOT 9
- About the encoder model
- Models download link provided. HOT 3
- Some Code Problem HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from stegastamp.