Python Lambda Row If Statement