#include <bits/stdc++.h>
using namespace std;
int h[200008];
int h2[20008];
int a[508];
int x[508], y[508];
int tag[508];
int n, m;
int pre(int i) {
  if (i == 1)
    return n;
  else
    return i - 1;
}
int next(int i) {
  if (i == n)
    return 1;
  else
    return i + 1;
}
int get(int p, int p1, int p2) {
  return (abs(x[p] - x[p1]) + abs(y[p] - y[p1]) + abs(x[p1] - x[p2]) +
          abs(y[p1] - y[p2]));
}
bool slove(int p) {
  if (tag[pre(p)] == 1) return true;
  int p1, p2, dd;
  p1 = pre(p);
  p2 = next(p);
  dd = get(p1, p, p2);
  if (h[dd] > 0) {
    h[dd]--;
    tag[p] = 1;
    return true;
  } else {
    p2 = pre(p);
    p1 = pre(p2);
    dd = get(p1, p2, p);
    if (h[dd] > 0) {
      h[dd]--;
      tag[p2] = 1;
      return true;
    }
  }
  return false;
}
bool slove2(int p) {
  if (tag[pre(p)] == 1) return true;
  int p1, p2, dd;
  p1 = pre(p);
  p2 = next(p);
  dd = get(p1, p, p2);
  if (h2[dd] > 0) {
    h2[dd]--;
    tag[p] = 1;
    return true;
  } else {
    p2 = pre(p);
    p1 = pre(p2);
    dd = get(p1, p2, p);
    if (h2[dd] > 0) {
      h2[dd]--;
      tag[p2] = 1;
      return true;
    }
  }
  return false;
}
int main() {
  scanf("%d %d", &n, &m);
  for (int i = 1; i <= n; i++) {
    scanf("%d %d", &x[i], &y[i]);
  }
  for (int i = 1; i <= m; i++) {
    scanf("%d", &a[i]);
    h[a[i]]++;
    h2[a[i]]++;
  }
  int ff = 1;
  for (int i = 1; i <= n; i++) {
    if (slove(i) == false) {
      ff = 0;
      break;
    }
  }
  if (!ff) {
    fill(tag, tag + 502, 0);
    for (int i = 2;; i = next(i)) {
      if (slove2(i) == false) {
        cout << "NO";
        return 0;
      }
      if (i == 1) break;
    }
  }
  cout << "YES" << endl;
  for (int i = 1; i <= n; i++) {
    if (tag[i] == 1) {
      int p1 = pre(i);
      int p2 = next(i);
      int dd = get(p1, i, p2);
      for (int j = 1; j <= m; j++) {
        if (a[j] == dd) {
          cout << j << " ";
          a[j] = -1;
          break;
        }
      }
    } else
      cout << "-1 ";
  }
}
