Seed std::mt19937 from std::random_device
Well, first off, why do you use a std::vector for a comparatively small sequence of known length? A raw array or std::array suffice and avoids any dynamic allocation.

Next, avoid needless magic numbers. Use std::mt19937::state_size instead of manually specifying 624.

Why do you use a lambda? A simple std::ref(source) suffices.


The seeding itself looks perfectly fine and there's no actual error anywhere in your code.
template&lt;class T = std::mt19937, std::size_t N = T::state_size * sizeof(typename T::result_type)&gt;
auto ProperlySeededRandomEngine () -&gt; typename std::enable_if&lt;N, T&gt;::type {
    std::random_device source;
    std::random_device::result_type random_data[(N - 1) / sizeof(source()) + 1];
    std::generate(std::begin(random_data), std::end(random_data), std::ref(source));
    std::seed_seq seeds(std::begin(random_data), std::end(random_data));
    return T(seeds);
}

You could avoid the need for random_data by using counting and transforming iterators as detailed in &quot;Sequence iterator? Isn't there one in boost?&quot;.
This is not simpler, but maybe more efficient:
template&lt;class T = std::mt19937, std::size_t N = T::state_size * sizeof(typename T::result_type)&gt;
T ProperlySeededRandomEngine () {
    std::random_device source;
    auto make_iter = [&amp;](std::size_t n) {
    return boost::make_transform_iterator(
        boost::counting_iterator&lt;std::size_t&gt;(n), [&amp;](size_t){return source();});
    };
    std::seed_seq seeds(make_iter(0), make_iter((N - 1) / sizeof(source()) + 1));
    return T(seeds);
}

On coliru