import java.io.*;
import java.util.*;

public class theater_md implements Runnable {
	private static final double infty = Double.MAX_VALUE;
	private Scanner in;
	private PrintWriter out;

	public void solve() {
		in.nextInt();
		int len = in.nextInt();
		double v1 = in.nextInt();
		double v2 = in.nextInt();
		int n = in.nextInt();
		int[] x = new int[n];
		int[] y = new int[n];
		for (int i = 0; i < n; i++) {
			x[i] = in.nextInt();
			y[i] = in.nextInt();
		}
		
		double[][][] dist = new double[1 << n][2][2];
		for (int oa = 0; oa < 2; oa++) {
			double[][] d = new double[1 << n][n];
			for (int mask = 1; mask < (1 << n); mask++) {
				Arrays.fill(d[mask], infty);
			}
			for (int i = 0; i < n; i++) {
				d[1 << i][i] = (oa == 0) ? x[i] : (len - x[i]);
			}
			for (int mask = 1; mask < (1 << n); mask++) {
				dist[mask][oa][0] = dist[mask][oa][1] = infty;
				for (int last = 0; last < n; last++) {
					if ((mask & (1 << last)) == 0)
						continue;
					dist[mask][oa][0] = Math.min(dist[mask][oa][0], d[mask][last] + x[last]);
					dist[mask][oa][1] = Math.min(dist[mask][oa][1], d[mask][last] + len - x[last]);
					for (int i = 0; i < n; i++) {
						if ((mask & (1 << i)) != 0)
							continue;
						d[mask | (1 << i)][i] = Math.min(d[mask | (1 << i)][i], d[mask][last] + Math.hypot(x[i] - x[last], y[i] - y[last]));
					}
				}
			}
		}
		dist[0][0][1] = dist[0][1][0] = len;
		
		int m = in.nextInt();
		double[][][] a = new double[m][2][2];
		a[0][0][0] = a[0][1][0] = a[0][1][1] = infty;
		double ans = 0;
		int old = 0;
		for (int act = 0; act < m; act++) {
			int k = in.nextInt();
			int nov = 0;
			for (int i = 0; i < k; i++) {
				nov |= 1 << (in.nextInt() - 1);
			}
			int on = nov & (~old);
			int off = (~nov) & old;
			old = nov;
			if (act == 0)
				continue;
			ans = infty;
			for (int na = 0; na < 2; na++) {
				for (int nb = 0; nb < 2; nb++) {
					double best = infty;
					for (int oa = 0; oa < 2; oa++) {
						for (int ob = 0; ob < 2; ob++) {
							best = Math.min(best, a[act - 1][oa][ob] + Math.max(dist[on][oa][na] / v1, dist[off][ob][nb] / v2));
						}
					}
					a[act][na][nb] = best;
					ans = Math.min(ans, best);
				}
			}
		}
		out.println(ans);
	}
	
	@Override
	public void run() {
		try {
			in = new Scanner(new FileReader("theater.in"));
			out = new PrintWriter(new File("theater.out"));
			solve();
			in.close();
			out.close();
		} catch (IOException e) {
			e.printStackTrace();
			System.exit(1);
		}
	}
	
	public static void main(String[] args) throws IOException {
		Locale.setDefault(Locale.US);
		new Thread(new theater_md()).start();
	}
}
