added Gain in attributes - Fixed padNan issue