Discussion:
[theano-users] 2nd (and 3rd) highest value of a 2D tensor
Andre Holzner
2017-05-04 09:58:35 UTC
Permalink
Good morning,

I want to get the 2nd (and possibly 3rd) highest value in a 2D tensor
(output of a convolutional layer).

What would be the simplest way of implementing this in Theano ?

I saw that there is support for iterating
(http://deeplearning.net/software/theano/library/scan.html )
and IfElse operations
(http://deeplearning.net/software/theano/tutorial/conditions.html), that
in principle should allow me to implement this ? Will this also generate
CUDA code when I run
with the GPU backend or will the operation be performed on the CPU ?

thanks a lot,

Andre
--
---
You received this message because you are subscribed to the Google Groups "theano-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to theano-users+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Frédéric Bastien
2017-05-05 17:26:41 UTC
Permalink
Check this issue:

https://github.com/Theano/Theano/issues/5608

Using scan for that is a bad idea, it would be very slow. There isn't a
very good solution right now, but in this issue, it indicate some way to do
that.

Fred
Post by Andre Holzner
Good morning,
I want to get the 2nd (and possibly 3rd) highest value in a 2D tensor
(output of a convolutional layer).
What would be the simplest way of implementing this in Theano ?
I saw that there is support for iterating (
http://deeplearning.net/software/theano/library/scan.html )
and IfElse operations (
http://deeplearning.net/software/theano/tutorial/conditions.html), that
in principle should allow me to implement this ? Will this also generate
CUDA code when I run
with the GPU backend or will the operation be performed on the CPU ?
thanks a lot,
Andre
--
---
You received this message because you are subscribed to the Google Groups
"theano-users" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
---
You received this message because you are subscribed to the Google Groups "theano-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to theano-users+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...