Convert the visualization script to an AMD module