<commit_before>General Information
===

LifeAPI provides comfortable functions (API) to manipulate, iterate, evolve, compare and report Life objects. This is mainly done in order to provide fast (using C++) but still comfortable search utility. 

LifeAPI is C++ application (compiles only with c++ compiler, specifically g++ is recommended), that uses mainly the overload functionality of C++. It doesn't use classes, and compiling it will not require Make, you only need to #include "LifeAPI.h". Many times it's the only #include that you will need, for this sort of applications. It works as fast as C. 

LifeAPI can utilize all 64 bits of 64 bit machine. That means if you compile it on 64-bit, it will work twice as fast just due to 64 bit, just make sure to set the compiler options correctly. Of course it utilize the full potential of 32 bit machine as well. 

LifeAPI uses CamelCase convention for its functions, but it's very similar to golly python functionality, naming, and parameters input/overloads. As it was made to replace to some extent search I've made previously in golly, much of golly function naming and other conventions are present. 

How to use
---

1. Download  [LifeAPI.h](https://github.com/simsim314/LifeAPI/blob/master/LifeAPI.h)
2. Place it in the same folder with you code.
3. #include "LifeAPI.h" in your code. 
4. Compile with C++ compiler.
5. See samples [here](https://github.com/simsim314/LifeAPI). 

Enjoy. 


API Documentation 
==========
---
---


General
====


LifeAPI works with object called **LifeState** (like cells in golly). Each state is 64x64. The iterations are on torus.  
Each LifeState is treated as part of the universe, with (0, 0) in the centre. Each LifeStates contains array of N longs, 
and Life Rule is hard coded into bitwise iteration. LifeStates also contain min and max - and don't iterate on all the space when it's not necessary. Automatic emitted glider removal was added, into emittedGldiers property of LifeState, with information about where the gliders were found, like their direction, generation and location. 
 
**NOTE:** min-max are not optimized to use torus, and patterns that use the torus properties of LifeAPI will work slower.

**NOTE:** LifeStates is "column" based, in the sense that long and thin patterns will work faster, but this is usually neglectable - unless one has very long and very thin pattern. 
<commit_msg>Note to check UnitTest.c was added.<commit_after>General Information
===

LifeAPI provides comfortable functions (API) to manipulate, iterate, evolve, compare and report Life objects. This is mainly done in order to provide fast (using C++) but still comfortable search utility. 

LifeAPI is C++ application (compiles only with c++ compiler, specifically g++ is recommended), that uses mainly the overload functionality of C++. It doesn't use classes, and compiling it will not require Make, you only need to #include "LifeAPI.h". Many times it's the only #include that you will need, for this sort of applications. It works as fast as C. 

LifeAPI can utilize all 64 bits of 64 bit machine. That means if you compile it on 64-bit, it will work twice as fast just due to 64 bit, just make sure to set the compiler options correctly. Of course it utilize the full potential of 32 bit machine as well. 

LifeAPI uses CamelCase convention for its functions, but it's very similar to golly python functionality, naming, and parameters input/overloads. As it was made to replace to some extent search I've made previously in golly, much of golly function naming and other conventions are present. 

How to use
---

1. Download  [LifeAPI.h](https://github.com/simsim314/LifeAPI/blob/master/LifeAPI.h)
2. Place it in the same folder with you code.
3. #include "LifeAPI.h" in your code. 
4. Compile with C++ compiler.
5. See samples [here](https://github.com/simsim314/LifeAPI). 

Enjoy. 


**NOTE** LifeAPI is in rapid development so we update the UnitTest.c to its latest abilities (actually no commit is done before the UnitTest.c was updated and made sure to work properly, with the latest changes). The samples might be outdated, or even not work. 

API Documentation 
==========
---


General
====


LifeAPI works with object called **LifeState** (like cells in golly). Each state is 64x64. The iterations are on torus.  
Each LifeState is treated as part of the universe, with (0, 0) in the centre. Each LifeStates contains array of N longs, 
and Life Rule is hard coded into bitwise iteration. LifeStates also contain min and max - and don't iterate on all the space when it's not necessary. Automatic emitted glider removal was added, into emittedGldiers property of LifeState, with information about where the gliders were found, like their direction, generation and location. 
 
**NOTE:** min-max are not optimized to use torus, and patterns that use the torus properties of LifeAPI will work slower.

**NOTE:** LifeStates is "column" based, in the sense that long and thin patterns will work faster, but this is usually neglectable - unless one has very long and very thin pattern. 

{'fraction_non_alphanumeric': 0.0673605655930872, 'fraction_numerical': 0.010604870384917517, 'mean_word_length': 4.207566462167689, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1478763', 'n_tokens_mistral': 1373, 'n_tokens_neox': 1255, 'n_words': 775}