<commit_before>#include <log4cxx/logger.h>
#include <KrisLibrary/Logger.h>
#include "three.js.h"
#include <KrisLibrary/meshing/MeshPrimitives.h>
//#include <boost/uuid/uuid.hpp>            // uuid class
//#include <boost/uuid/uuid_generators.hpp> // generators
//#include <boost/uuid/uuid_io.hpp>         // streaming operators etc.
#include <random>
#include <sstream>
using namespace std;

unsigned char FloatColorChar(float v)
{
  return Max(Min(int(v*255.0),255),0);
}
int ToRGB32(const GLDraw::GLColor& col)
{
  unsigned char r=FloatColorChar(col.rgba[0]);
  unsigned char g=FloatColorChar(col.rgba[1]);
  unsigned char b=FloatColorChar(col.rgba[2]);
  return r << 16 | g << 8 | b;
}

string MakeRandomUUID()
{
  char str[33];
  str[32]=0;
  char alphaNumeric[] = {'a','b','c','d','e','f','g','0','1','2','3','4','5','6','7','8','9'};
  //make a 36 char long string
  std::default_random_engine generator;
  std::uniform_int_distribution<int> distribution(0,15);

  //boost::uuids::uuid uuid = boost::uuids::random_generator()();
  for(int i = 0; i<32; i++){
    str[i] = alphaNumeric[distribution(generator)];
  }
  //ss << uuid;
  return string(str);
}

struct ThreeJSCache
{<commit_msg>Fixed UUID generator boost replacement<commit_after>#include <log4cxx/logger.h>
#include <KrisLibrary/Logger.h>
#include "three.js.h"
#include <KrisLibrary/meshing/MeshPrimitives.h>
#include <KrisLibrary/math/random.h>
//#include <boost/uuid/uuid.hpp>            // uuid class
//#include <boost/uuid/uuid_generators.hpp> // generators
//#include <boost/uuid/uuid_io.hpp>         // streaming operators etc.
#include <sstream>
using namespace std;

unsigned char FloatColorChar(float v)
{
  return Max(Min(int(v*255.0),255),0);
}
int ToRGB32(const GLDraw::GLColor& col)
{
  unsigned char r=FloatColorChar(col.rgba[0]);
  unsigned char g=FloatColorChar(col.rgba[1]);
  unsigned char b=FloatColorChar(col.rgba[2]);
  return r << 16 | g << 8 | b;
}

string MakeRandomUUID()
{
  char str[33];
  str[32]=0;
  char alphaNumeric[] = {'a','b','c','d','e','f','g','0','1','2','3','4','5','6','7','8','9'};
  //make a 32 char long string
  
  //boost::uuids::uuid uuid = boost::uuids::random_generator()();
  for(int i = 0; i<32; i++){
    str[i] = alphaNumeric[Math::RandInt(16)];
  }
  //ss << uuid;
  return string(str);
}

struct ThreeJSCache
{
{'fraction_non_alphanumeric': 0.19905619905619906, 'fraction_numerical': 0.03389103389103389, 'mean_word_length': 4.660194174757281, 'pattern_counts': {'":': 0, '<': 34, '<?xml version=': 0, '>': 20, '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': '1302561', 'n_tokens_mistral': 900, 'n_tokens_neox': 867, 'n_words': 172}