<commit_before>#include "bayesian/graph.hpp"
#include "bayesian/sampling.hpp"

namespace bn {

matrix_type sampling::operator()(
    graph_t const& graph,
    vertex_type const& node,
    std::vector<std::pair<vertex_type, int>> const& condition
    )
{
    // パターン作る(generate_pattern)
    auto const generated_patterns = generate_pattern(graph, 100/*tmp*/, condition);

    // 数え上げを行う
    bn::matrix_type result(node->selectable_num, 1, 0.0);
	for(auto const& pattern : generated_patterns)
	{
		result[pattern.at(node)][0] += 1.0;
	}<commit_msg>update: edit sample num.<commit_after>#include "bayesian/graph.hpp"
#include "bayesian/sampling.hpp"

namespace bn {

matrix_type sampling::operator()(
    graph_t const& graph,
    vertex_type const& node,
    std::vector<std::pair<vertex_type, int>> const& condition
    )
{
    // パターン作る(generate_pattern)
    auto const generated_patterns = generate_pattern(graph, 10000/*tmp*/, condition);

    // 数え上げを行う
    bn::matrix_type result(node->selectable_num, 1, 0.0);
	for(auto const& pattern : generated_patterns)
	{
		result[pattern.at(node)][0] += 1.0;
	}
{'fraction_non_alphanumeric': 0.1429864253393665, 'fraction_numerical': 0.01809954751131222, 'mean_word_length': 4.448275862068965, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 9, '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': '5371097', 'n_tokens_mistral': 421, 'n_tokens_neox': 391, 'n_words': 75}