<commit_before>#include "Software.h"

#include <iostream>
#include <fstream>
#include <algorithm>

#ifndef min
#define min(X, Y) (((X) < (Y)) ? (X) : (Y))
#endif

#ifndef max
#define max(X, Y) (((X) > (Y)) ? (X) : (Y))
#endif

OpenALRF::ImageProcessingSoftware::ImageProcessingSoftware()
{
   Original.Buffer = nullptr;
   Original.BufferLength = 0;
   Grayscale.Buffer = nullptr;
   Grayscale.BufferLength = 0;
   ObjectMask.Buffer = nullptr;
   ObjectMask.BufferLength = 0;
}

OpenALRF::ImageProcessingSoftware::~ImageProcessingSoftware()
{
}

void OpenALRF::ImageProcessingSoftware::Initialize(const CapturedImage AImage)
{
   Original = AImage;

   WriteToBMP("original.bmp", AImage);
}

bool OpenALRF::ImageProcessingSoftware::AllocateBuffer(CapturedImage * AImage)
{
   AImage->BufferLength = AImage->Width * AImage->Height * AImage->Channels;
   AImage->Buffer = new unsigned char[AImage->BufferLength];
   if (AImage->Buffer == nullptr)
   {<commit_msg>buildfix<commit_after>#include "Software.h"

#include <iostream>
#include <fstream>
#include <algorithm>
#include <cstring>

#ifndef min
#define min(X, Y) (((X) < (Y)) ? (X) : (Y))
#endif

#ifndef max
#define max(X, Y) (((X) > (Y)) ? (X) : (Y))
#endif

OpenALRF::ImageProcessingSoftware::ImageProcessingSoftware()
{
   Original.Buffer = nullptr;
   Original.BufferLength = 0;
   Grayscale.Buffer = nullptr;
   Grayscale.BufferLength = 0;
   ObjectMask.Buffer = nullptr;
   ObjectMask.BufferLength = 0;
}

OpenALRF::ImageProcessingSoftware::~ImageProcessingSoftware()
{
}

void OpenALRF::ImageProcessingSoftware::Initialize(const CapturedImage AImage)
{
   Original = AImage;

   //WriteToBMP("original.bmp", AImage);
}

bool OpenALRF::ImageProcessingSoftware::AllocateBuffer(CapturedImage * AImage)
{
   AImage->BufferLength = AImage->Width * AImage->Height * AImage->Channels;
   AImage->Buffer = new unsigned char[AImage->BufferLength];
   if (AImage->Buffer == nullptr)
   {
{'fraction_non_alphanumeric': 0.152218782249742, 'fraction_numerical': 0.0030959752321981426, 'mean_word_length': 5.399339933993399, 'pattern_counts': {'":': 0, '<': 12, '<?xml version=': 0, '>': 26, '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': '4710889', 'n_tokens_mistral': 672, 'n_tokens_neox': 649, 'n_words': 130}