srush / Tensor-Puzzles

Solve puzzles. Improve your pytorch.
MIT License
2.96k stars 242 forks source link

Is `.bool()` or `.long()` allowed? #30

Closed shenoynikhil closed 2 months ago

shenoynikhil commented 2 months ago

Is changing types using .bool() or .long() allowed? I am using these to create masks in some questions?

shenoynikhil commented 2 months ago

I just saw your comment in #9 where you mention using * 1 to force to long type. But happy to hear your thoughts.

srush commented 2 months ago

Yeah that's fine. I should fix the tests.

On Wed, May 22, 2024 at 2:22 AM Nikhil Shenoy @.***> wrote:

I just saw your comment in #9 https://github.com/srush/Tensor-Puzzles/issues/9 where you mention using * 1 to force to long type. But happy to hear your thoughts.

— Reply to this email directly, view it on GitHub https://github.com/srush/Tensor-Puzzles/issues/30#issuecomment-2123951493, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAIYKVIPP7GWYHOZ4RW5BTZDQ2RJAVCNFSM6AAAAABIC5JF2SVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMRTHE2TCNBZGM . You are receiving this because you are subscribed to this thread.Message ID: @.***>