#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1e9 + 7;
const long long N = 2000;
long long fact[N];
void init() {
  fact[0] = 1;
  for (long long i = 1; i < N; i++) fact[i] = fact[i - 1] * i % MOD;
}
long long fastpow(long long n, long long p) {
  long long res = 1;
  while (p) {
    if (p & 1) res = (res * n) % MOD;
    n = n * n % MOD;
    p >>= 1;
  }
  return res;
}
signed main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  init();
  long long n, m;
  cin >> n >> m;
  cout << fact[n + 2 * m - 1] * fastpow(fact[2 * m], MOD - 2) % MOD *
              fastpow(fact[n - 1], MOD - 2) % MOD
       << "\n";
}
