#include <bits/stdc++.h>
using namespace std;
int main() {
  int T;
  scanf("%d", &T);
  while (T--) {
    int n, a, o;
    vector<pair<pair<int, int>, int> > M;
    scanf("%d", &n);
    M.push_back(make_pair(make_pair(0, 0), 0));
    for (int i = 1; i <= n * 2 - 1; i++) {
      scanf("%d%d", &a, &o);
      M.push_back(make_pair(make_pair(a, o), i));
    }
    sort(M.begin(), M.end());
    long long s[2] = {0};
    for (int i = 1; i <= n * 2 - 1; i++) {
      s[i & 1] += M[i].first.second;
    }
    printf("YES\n");
    if (s[1] > s[0]) {
      for (int i = 1; i <= n * 2 - 1; i += 2) {
        printf("%d ", M[i].second);
      }
    } else {
      for (int i = 2; i <= n * 2 - 1; i += 2) {
        printf("%d ", M[i].second);
      }
      printf("%d", M[n * 2 - 1].second);
    }
    printf("\n");
  }
}
