init d3 and flask template