#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int TESTS = 1;
  cin >> TESTS;
  while (TESTS--) {
    long long n, k, i, j, l, m;
    cin >> n >> k;
    long long a[200004];
    for (i = 0; i < n; i++) cin >> a[i];
    long long sum = 0, ss = 0;
    l = 0;
    vector<long long int> ans;
    for (i = 0; i < n; i++) {
      ss += a[i];
      sum += a[i];
      if (sum % 2 == 1) {
        sum = 0;
        ans.push_back(i + 1);
        l++;
      }
    }
    if (l >= k - 1 && (l - k) % 2 == 0 && ss % 2 == k % 2) {
      cout << "YES\n";
      for (i = l - k; i < l - 1; i++) cout << ans[i] << " ";
      cout << n;
      cout << '\n';
    } else
      cout << "NO\n";
  }
  return 0;
}
