Map transformation by template