It would be better to take a bus from Pune to Mangalore and take a train from Mangalore Jn/Central towards Ernakulam (even buses are available). You would reach Ernakulam within 20-24 hours. It is very slow train and the journey would be exhausting. The coaches are in borderline horrible condition (especially sleeper ones, no clue about AC coaches) and you would be witnessing many trains crossing while this one would be on loop after Madgaon Junction. If your sole purpose is to witness the landscapes of Karnataka and Konkan Region, then this train would be great delight.