The error is due to the fact that neither g0 nor g1 are initialized. They have simply been declared as a metric and a type (0,2) tensor field, but you should initialize their components in some vector frame, in order to fully define them.