deviation-network icon indicating copy to clipboard operation
deviation-network copied to clipboard

TF2 implementation

Open ASALASSA opened this issue 3 years ago • 1 comments

Hi Mr Pang. I have read your paper and I found it very interesting to replicate. Congratulations!

I am currently trying to explore your ideas and to implement them in a fraud prevention context but I found some trouble trying to adapt your code to tf2 and our dataset. I am experimenting problems with the code, particularly inside the custom cost function.

The first one occurs with the ref variable. The framework throws the following error: tf.function-decorated function tried to create variables on non-first call. One solution would be to declare the symbolic variable outside the function but the random sample from which the mean and variance are obtained would always be the same. On the other hand, for debugging purposes only, we train the model in eager mode and the error we encountered is: assertion failed: [predictions must be> = 0] [Condition x> = y did not hold element-wise: ] ….

Have you or your team ever tried to migrate your code to tf2? It could be very helpful for us your experience.

Thank you.

ASALASSA avatar Jul 02 '21 02:07 ASALASSA

Hi, we didn't have similar problems, but we may release a PyTorch implementation of DevNet later. Stay tuned!

GuansongPang avatar Jul 02 '21 03:07 GuansongPang