Metadata-Version: 2.3
Name: gamslib
Version: 0.2.6
Summary: Modules and subpackages used in various GAMS5 related projects
Project-URL: Homepage, https://github.com/DHGraz/gamslib
Project-URL: Repository, https://github.com/DHGraz/gamslib
Project-URL: Issues, https://github.com/DHGraz/gamslib/issues
Project-URL: Changelog, https://github.com/DHGraz/gamslib/blob/main/CHANGELOG.md
Author-email: Gunter Vasold <gunter.vasold@uni-graz.at>, Fabio Tosques <fabio.tosques@uni-graz.at>
Keywords: GAMS
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Software Development :: Libraries
Requires-Python: >=3.11
Requires-Dist: pydantic>=2.10.1
Requires-Dist: pylightxl>=1.61
Description-Content-Type: text/markdown

# gamslib

gamslib is a collection of GAMS related modules and packages, which are used in multiple other packages.


gamslib is available on pypi.org and can be installed via pip:

```
pip install gamslib
```

Currently these subpackages are available (more to come):

## objectcsv

Handle object and datastream metadata in object csv files.

When creating bags for GAMS, we provide some metadata in csv
files (which are not part of the bag, btw).

The objectcsv package provides tools to handle this metadata.

  * The ObjectCSV class represents the object    
    and datastream csv data for a single object. It is created by providing the 
    path to the  object directory. 
  * The manage_csv module can be used to collect csv data from all objects 
    into a single file, which makes editing the data more efficient.
    It also has a function to update the csv files in the object directories 
    based on the collected data.
  * The xlsx module can be used to convert the csv files to xlsx files 
    and vice versa. This is useful for editing the data in a spreadsheet 
    without the hassles of importing and exporting the csv files, which 
    led to encoding problems in the past.

## projectconfiguration

This package contains a central class `Configuration` that represents the 
project configuration. To create this object, the function 
`load_configuration(OBJECT_ROOT, [PATH_TO_TOML_FILE])` should be used.

The function tries to find the project configuration file, validates 
its content, and creates the central Configuration object with all 
sub-objects (Each TOML inline table is provided as its own sub-object). 
These sub-objects are currently:

  * general
  * metadata

A basic configuration file can be generated via the `create_condiguration()` function.