rtaori / Black-Box-Audio

Targeted Adversarial Examples for Black Box Audio Systems
MIT License
67 stars 30 forks source link

error in run_audio_attack.py #5

Closed shudong-zhang closed 4 years ago

shudong-zhang commented 4 years ago

ValueError: Input tensor 'ExpandDims:0' enters the loop with shape (1, 11), but has shape (1, ?) after one iteration. To allow the shape to vary across iterations, use the shape_invariants argument of tf.while_loop to specify a less-specific shape.

When I run run_audio_attack.py, I got an error list above.How to solve it ?

rtaori commented 4 years ago

Hi, It seems the DeepSpeech repo has been updated since this work was done. Could you try following the suggestion in https://github.com/rtaori/Black-Box-Audio/issues/4 ?

shudong-zhang commented 4 years ago

I can pass the make_checkpoint.py, so I don't think the error casued by version.

rtaori commented 4 years ago

Right yes, but run_audio_attack.py still makes calls to the DeepSpeech library, so if anything there has changed then it could break the program. Could you try reverting to the commit specified in #4? I have tested it on that version so it should work.

rtaori commented 3 years ago

hi @zhangdong1992,

I have updated the installation instructions with much more detail in the README. Please follow the steps there and open another issue if you still have any problems.