#include <bits/stdc++.h>
using namespace std;
namespace Dango {
const int MAXN = 100005;
long long n, s;
int d[MAXN], ans[MAXN], res;
bool judge(int a) {
  long long tmp = n * (n + 1) / 2 - s;
  for (int i = 1; i <= n; i++) d[i] = 1;
  long long pos = 1, last = n;
  while (tmp) {
    while (pos == 1 || d[pos] == d[pos - 1] * a) pos++;
    if (last <= pos) return false;
    long long x = min(tmp, last - pos);
    d[last - x]++;
    d[last]--;
    if (!d[last]) last--;
    tmp -= x;
  }
  return true;
}
void update() {
  for (int i = 1; i <= n; i++) ans[i] = d[i];
}
int work() {
  ios::sync_with_stdio(false);
  cin >> n >> s;
  if (s > n * (n + 1) / 2 || s < 2 * n - 1) {
    cout << "No";
    return 0;
  }
  int l = 1, r = n - 1;
  while (l <= r) {
    int mid = (l + r) >> 1;
    if (judge(mid)) {
      update();
      res = mid;
      r = mid - 1;
    } else
      l = mid + 1;
  }
  cout << "Yes\n";
  for (int i = 1; i <= n; i++) ans[i] += ans[i - 1];
  for (int i = 2; i <= n; i++) {
    if (ans[i] == ans[i - 1]) break;
    int f = ans[i - 2] + 1, cnt = 0;
    for (int j = ans[i - 1] + 1; j <= ans[i]; j++) {
      cout << f << " ";
      cnt++;
      if (cnt == res) {
        f++;
        cnt = 0;
      }
    }
  }
  return 0;
}
}  // namespace Dango
int main() { return Dango::work(); }
