Global Weierstrass equations of hyperelliptic curves