<commit_before># version 130


in vec2 Texcoord;

const int max_iter = 200;
const float radius = 100.0;


out vec4 result;

void main()
{
    int count = 0;
    vec2 p = vec2(-2.1+ 2.9 * Texcoord.x, -1.16 + 2.32 * Texcoord.y);

    vec2 z = vec2(0.0);
    
    for(int i=0; i< max_iter; i++)
    {
      z = vec2(z.x * z.x - z.y * z.y, 2 * z.x * z.y) + p;
      if (dot(z, z) > radius)
          break;
      count += 1;
    }
    if (count == max_iter)
        { result = vec4(0.0, 0.0, 0.0, 1.0);}
    else {

    float v = count + 1 - log2(log2(sqrt(dot(z, z))));
    v = log2(v) / 5.0;
    vec3 color = vec3(0.0);
    if (v < 1.0)
        {color = vec3(pow(v, 4), pow(v, 2.5), v);}
    else
        {v = max(0, 2.0 - v);
         color = vec3(v, pow(v, 1.5), pow(v, 3));
        }
        result = vec4(color, 1.0);
    }
}<commit_msg>:monkey: add new penrose scene, add madelbrot example for pyglet<commit_after># version 130

in vec2 Texcoord;

const int max_iter = 200;
const float radius = 100.0;

out vec4 result;

void main()
{
    int count = 0;
    vec2 p = vec2(-2.1+ 2.9 * Texcoord.x, -1.16 + 2.32 * Texcoord.y);
    vec2 z = vec2(0.0);
    
    for(int i=0; i< max_iter; i++)
    {
      z = vec2(z.x * z.x - z.y * z.y, 2 * z.x * z.y) + p;
      if (dot(z, z) > radius)
          break;
      count += 1;
    }
    if (count == max_iter)
    {
        result = vec4(0.0, 0.0, 0.0, 1.0);
    }
    else
    {
        float v = count + 1 - log2(log2(sqrt(dot(z, z))));
        v = log2(v) / 5.0;
        vec3 color = vec3(0.0);
        if (v < 1.0)
        {
            color = vec3(pow(v, 4), pow(v, 2.5), v);
        }
        else
        {
            v = max(0, 2.0 - v);
            color = vec3(v, pow(v, 1.5), pow(v, 3));
        }
        result = vec4(color, 1.0);
    }
}
{'fraction_non_alphanumeric': 0.18652561247216035, 'fraction_numerical': 0.0757238307349666, 'mean_word_length': 1.5561877667140824, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 5, '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': '6250503', 'n_tokens_mistral': 849, 'n_tokens_neox': 787, 'n_words': 205}