<commit_before>#ifndef LOCAL_GVT_MANAGER
#define LOCAL_GVT_MANAGER

#include <mutex>
#include <atomic>
#include <memory>

namespace warped {

class TimeWarpLocalGVTManager {
public:
    TimeWarpLocalGVTManager() = default;

    void initialize(unsigned int num_local_objects);

    bool startGVT();
    bool completeGVT();

    void resetState();

    void receiveEventUpdateState(unsigned int timestamp, unsigned int thread_id);

    void sendEventUpdateState(unsigned int timestamp, unsigned int thread_id);

    unsigned int getGVT() { return gVT_; }

protected:
    unsigned int getMinimumLVT();

private:
    unsigned int gVT_ = 0;

    std::atomic<unsigned int> local_gvt_flag_ = ATOMIC_VAR_INIT(0);

    // local minimum of each object including unprocessed events and sent events
    std::unique_ptr<unsigned int []> local_min_;

    // minimum timestamp of sent events used for minimum local min calculation
    std::unique_ptr<unsigned int []> send_min_;

    // flag to determine if object has already calculated min<commit_msg>Changed incorrectly name parameter<commit_after>#ifndef LOCAL_GVT_MANAGER
#define LOCAL_GVT_MANAGER

#include <mutex>
#include <atomic>
#include <memory>

namespace warped {

class TimeWarpLocalGVTManager {
public:
    TimeWarpLocalGVTManager() = default;

    void initialize(unsigned int num_local_objects);

    bool startGVT();
    bool completeGVT();

    void resetState();

    void receiveEventUpdateState(unsigned int timestamp, unsigned int local_object_id);

    void sendEventUpdateState(unsigned int timestamp, unsigned int local_object_id);

    unsigned int getGVT() { return gVT_; }

protected:
    unsigned int getMinimumLVT();

private:
    unsigned int gVT_ = 0;

    std::atomic<unsigned int> local_gvt_flag_ = ATOMIC_VAR_INIT(0);

    // local minimum of each object including unprocessed events and sent events
    std::unique_ptr<unsigned int []> local_min_;

    // minimum timestamp of sent events used for minimum local min calculation
    std::unique_ptr<unsigned int []> send_min_;

    // flag to determine if object has already calculated min
{'fraction_non_alphanumeric': 0.07674088109900522, 'fraction_numerical': 0.0018948365703458077, 'mean_word_length': 4.443298969072165, 'pattern_counts': {'":': 0, '<': 15, '<?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': '498581', 'n_tokens_mistral': 621, 'n_tokens_neox': 593, 'n_words': 194}