#include <bits/stdc++.h>
using namespace std;
inline int read() {
  int s = 0, w = 1;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') w = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') s = s * 10 + ch - '0', ch = getchar();
  return s * w;
}
int main() {
  int T = read();
  while (T--) {
    int n = read(), a = read(), flag = 0, k;
    for (int i = 2; i <= n; i++) {
      int b = read();
      if (abs(a - b) >= 2) {
        k = i;
        flag = 1;
      }
      a = b;
    }
    if (flag)
      cout << "YES\n" << k - 1 << " " << k << endl;
    else
      cout << "NO\n";
  }
  return 0;
}
