#include <bits/stdc++.h>
using namespace std;
vector<int> x, y;
vector<int> a;
vector<int> ans;
int m, n;
int d(int p1, int p2) {
  p1 %= n;
  p2 %= n;
  return abs(x[p1] - x[p2]) + abs(y[p1] - y[p2]);
}
bool solve() {
  vector<int> used(m, 0);
  ans.resize(n, -1);
  for (int i = 0; i < n; i += 2) {
    int l = d(i, i + 2);
    bool ok = false;
    for (int j = 0; j < m; j++) {
      if (!used[j] && a[j] == l) {
        used[j] = 1;
        ok = true;
        ans[i + 1] = j + 1;
        break;
      }
    }
    if (!ok) return false;
  }
  return true;
}
int main() {
  cin >> n >> m;
  x.resize(n);
  y.resize(n);
  for (int i = 0; i < n; i++) cin >> x[i] >> y[i];
  a.resize(m);
  for (int i = 0; i < m; i++) cin >> a[i];
  if (n % 2) {
    cout << "NO" << endl;
    return 0;
  }
  bool solved = solve();
  if (!solved) {
    int xt = x[0];
    int yt = y[0];
    x.erase(x.begin());
    y.erase(y.begin());
    x.push_back(xt);
    y.push_back(yt);
    solved = solve();
    int at = ans[n - 1];
    ans.insert(ans.begin(), at);
  }
  if (!solved)
    cout << "NO" << endl;
  else {
    cout << "YES" << endl;
    for (int i = 0; i < n; i++) cout << ans[i] << " ";
    cout << endl;
  }
  return 0;
}
