|
Learning Curve Plus Plus (LCPP)
|
This folder contains general-purpose utilities that are used in LCPP.
Together, these utilities form a lightweight toolkit for handling common tasks such as data serialization, HTTP requests, CLI argument management, and progress reporting.
Each utility is self-contained and can be used independently, but together they simplify common development patterns and improve code readability and reusability.
Overall, we use the cereal library for serialization and de-serialization purposes. However, not every object is directly available for serialization. If you want to contribute to LCPP and your contribution requires the serialization and de-serialization for a C++ object then please add it here and test it. For now, only std::optinal<T> and std::filesystem::path additions are present.
The curl utility provides a modern C++ wrapper around libcurl for performing HTTP and HTTPS requests. In this project it is used to download datasets from OpenML. Here, I have added a utility function to be able to convert the downloaded data to a string.
This is a lightweight configuration class. It enables one to register some variables that might come in handy for relatively large projects. It is by design a singleton, hence we need to use the GetInstance() method to initialize it in our program. Then one can register variables as fundamental types with default values and can also choose to add a range of values that the variable can take with std::vector. You can access the variable from this singleton object and access its variables. Moreover, you can also print the used configuration to make sure all your variables are initialized as you wished. You can also generate unique names from the variables of your choice to make sure your output files are nicely tagged.
Now, you can run your program with ./program --id <someid> ... and change the variables you defined externally.
It is a lightweight thread sage progress bar for learning curve creation tracking, but you can use it for any loop that you want. You just need to name it give the ultimate number of the variables that you are iterating over and update it in your loop. A simple example is shown below.