<commit_before>#ifndef COFFEE_MILL_MATH_RMSD_CALCULATOR_HPP
#define COFFEE_MILL_MATH_RMSD_CALCULATOR_HPP
#include "Vector.hpp"

namespace mill
{

template<typename realT, std::size_t N>
realT rmsd(const std::vector<Vector<realT, N>>& lhs,
           const std::vector<Vector<realT, N>>& rhs)
{
    const std::size_t s = lhs.size();
    if(s != rhs.size())
        throw std::invalid_argument("rmsd: different size");

    realT sigma = 0.;
    for(std::size_t i=0; i<s; ++i) sigma += length_sq(lhs[i] - rhs[i]);
    const realT invN = 1. / static_cast<realT>(s);

    return std::sqrt(sigma * invN);
}

}// mill

#endif //COFFEE_MILL_RMSD_CALCLATOR
<commit_msg>:art: add blocks explicitly<commit_after>#ifndef COFFEE_MILL_MATH_RMSD_CALCULATOR_HPP
#define COFFEE_MILL_MATH_RMSD_CALCULATOR_HPP
#include "Vector.hpp"

namespace mill
{

template<typename realT, std::size_t N>
realT rmsd(const std::vector<Vector<realT, N>>& lhs,
           const std::vector<Vector<realT, N>>& rhs)
{
    const std::size_t s = lhs.size();
    if(s != rhs.size())
    {
        throw std::invalid_argument("rmsd: different size");
    }

    realT sigma = 0.;
    for(std::size_t i=0; i<s; ++i)
    {
        sigma += length_sq(lhs[i] - rhs[i]);
    }
    return std::sqrt(sigma / static_cast<realT>(s));
}

}// mill

#endif //COFFEE_MILL_RMSD_CALCLATOR

{'fraction_non_alphanumeric': 0.15303825956489123, 'fraction_numerical': 0.0037509377344336083, 'mean_word_length': 3.9962546816479403, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 15, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5974504', 'n_tokens_mistral': 555, 'n_tokens_neox': 540, 'n_words': 102}