https://sanskritmetres.appspot.com/ is the frontend for identifying metres. 

The source code is available at https://github.com/shreevatsa/sanskrit . 

With best wishes,