There is no dress code in BITS. One of my friends is from the Goa campus but I am pretty sure that things are the same across all three campuses. You can wear shorts and a t-shirt to the class.
In NIT Trichy, this depends on the professor whose class you're attending and depends on which year you are in. According to the classification –
In IIST, you can wear whatever you want but it should be within the limits of decency as seen by the current society. So there are no strict rules regarding the dress codes.