#include <bits/stdc++.h>
using namespace std;
long len[555], flag[555];
double x[555], y[555];
long dist(long a, long b) {
  return sqrt((x[a] - x[b]) * (x[a] - x[b]) + (y[a] - y[b]) * (y[a] - y[b]));
}
int main() {
  vector<long> v;
  long i, j, cnt, d, n, m;
  while (cin >> n >> m) {
    for (i = 0; i < n; i++) cin >> x[i] >> y[i];
    for (i = 0; i < m; i++) cin >> len[i];
    v.clear();
    cnt = 0;
    memset(flag, 0, sizeof(flag));
    for (i = 0; i < n; i += 2) {
      if (i == 0) {
        d = dist(n - 1, 0) + dist(0, 1);
      } else
        d = dist(i - 1, i) + dist(i, i + 1);
      for (j = 0; j < m; j++)
        if (d == len[j] && !flag[j]) {
          flag[j] = 1;
          cnt++;
          v.push_back(j);
          break;
        }
    }
    if (cnt == (n / 2) && (n / 2) <= m) {
      long c = 0;
      cout << "YES\n";
      for (i = 0; i < n; i += 2) {
        if (i == 0)
          cout << v[c++] + 1 << " -1";
        else
          cout << " " << v[c++] + 1 << " -1";
      }
      cout << endl;
      continue;
    }
    v.clear();
    cnt = 0;
    memset(flag, 0, sizeof(flag));
    for (i = 1; i < n; i += 2) {
      if (i == n - 1) {
        d = dist(n - 2, n - 1) + dist(n - 1, 0);
      } else
        d = dist(i - 1, i) + dist(i, i + 1);
      for (j = 0; j < m; j++)
        if (d == len[j] && !flag[j]) {
          flag[j] = 1;
          cnt++;
          v.push_back(j);
          break;
        }
    }
    if (cnt == (n / 2) && (n / 2) <= m) {
      long c = 0;
      cout << "YES\n";
      for (i = 0; i < n; i += 2) {
        if (i == 0)
          cout << "-1 " << v[c++] + 1;
        else
          cout << " -1 " << v[c++] + 1;
      }
      cout << endl;
    } else
      cout << "NO\n";
  }
  return 0;
}
