#include <bits/stdc++.h>
using namespace std;
const int maxN = (int)1E5;
const int maxM = 2 * maxN - 1;
int a[maxM], o[maxM], ps[maxM];
int n;
long long SumO;
bool key(int x, int y) { return a[x] < a[y]; }
int main() {
  int nTests;
  scanf("%d", &nTests);
  while (nTests--) {
    scanf("%d", &n);
    SumO = 0;
    for (int i = 0; i < 2 * n - 1; ++i) {
      scanf("%d %d", &a[i], &o[i]);
      SumO += o[i];
      ps[i] = i;
    }
    sort(ps, ps + 2 * n - 1, key);
    long long Sum[2] = {0, 0};
    for (int i = 0; i < 2 * n - 2; ++i) {
      Sum[i & 1] += o[ps[i]];
    }
    puts("YES");
    if (2 * Sum[0] >= SumO) {
      for (int i = 0; i < 2 * n - 2; i += 2) printf("%d ", ps[i] + 1);
    } else {
      for (int i = 1; i < 2 * n - 2; i += 2) printf("%d ", ps[i] + 1);
    }
    printf("%d\n", ps[2 * n - 2] + 1);
  }
  return 0;
}
