#include <bits/stdc++.h>
int n, m;
int cx[512], cy[512];
int len[512];
int ans[512];
int used[512];
int abs(int x) {
  if (x < 0) return -x;
  return x;
}
int getDist(int i1, int i2) {
  return abs(cx[i1] - cx[i2]) + abs(cy[i1] - cy[i2]);
}
int getDist(int i1, int i2, int i3) {
  i1 %= n;
  i2 %= n;
  i3 %= n;
  return getDist(i1, i2) + getDist(i2, i3);
}
int findDist(int dist) {
  for (int i = 0; i < m; i++)
    if (len[i] == dist && !used[i]) return i;
  return -1;
}
void printSolution() {
  printf("YES\n");
  for (int i = 0; i < n; i++) printf("%d ", ans[i]);
  printf("\n");
}
int main() {
  scanf("%d%d", &n, &m);
  for (int i = 0; i < n; i++) scanf("%d %d", cx + i, cy + i);
  for (int i = 0; i < m; i++) scanf("%d", len + i);
  memset(used, 0, sizeof(used));
  if (m * 2 < n)
    printf("NO\n");
  else {
    int ok = true;
    for (int i = 0; i < n - 1; i += 2) {
      int dist = getDist(i, i + 1, i + 2);
      int distidx = findDist(dist);
      if (distidx == -1) {
        ok = false;
        break;
      } else {
        used[distidx] = true;
        ans[i] = -1;
        ans[i + 1] = distidx + 1;
      }
    }
    if (ok)
      printSolution();
    else {
      ok = true;
      memset(used, 0, sizeof(used));
      for (int i = 1; i < n; i += 2) {
        int dist = getDist(i, i + 1, i + 2);
        int distidx = findDist(dist);
        if (distidx == -1) {
          ok = false;
          break;
        } else {
          used[distidx] = true;
          ans[i] = -1;
          ans[(i + 1) % n] = distidx + 1;
        }
      }
      if (ok)
        printSolution();
      else
        printf("NO\n");
    }
  }
}
