#include <bits/stdc++.h>
using namespace std;
struct Node {
  int x, y, num;
  bool operator<(Node B) const { return x < B.x; }
} a[200010];
int t, n;
int main() {
  cin >> t;
  while (t--) {
    scanf("%d", &n);
    for (int i = 1; i <= 2 * n - 1; ++i)
      scanf("%d%d", &a[i].x, &a[i].y), a[i].num = i;
    sort(a + 1, a + 2 * n);
    printf("YES\n");
    for (int i = 2; i < 2 * n - 1; i += 2) {
      if (a[i].y > a[i - 1].y)
        printf("%d ", a[i].num);
      else
        printf("%d ", a[i - 1].num);
    }
    printf("%d\n", a[2 * n - 1].num);
  }
  return 0;
}
