semvec/pypi-packages huggingface dataset:
bnf 1.0.5
A BNF (Backus-Naur Form) parser and a LL input sequence scanner with backtracking
License: MIT
Requires Python: >=3.6

A BNF (Backus-Naur Form) parser and a LL input sequence scanner with backtracking

BNF syntax:
===========

1. non-terminals between `<>`
2. rules end at newline `\n`
3. assign with `::=`
4. operators:
	* alternative derivations separated by `|`
	* group items between `()`
	* optional items between `{}` or with postfix `?` operator
	* zero or more repetitions with postfix `*` operator
	* one or more repetitions with postfix `+` operator
5. set of terminal values between `[]`: in set `[aeiou]`, not in set `[^aeiou]` or ranges `[a-z]`

The BNF compiler uses a LL parser with backtracking:

1. no left-recursion: `<X> :== <X> ...`
2. no `a+ a` alike sequences
3. longest rule first: rule `<X> ::= a | a b` must be replaced by `<X> ::= a b | a`
4. special chars `\\<>(){}[]|+*?:=` each must be quoted with `\\`

Grammar example for a python tuple of integer literals (`tuple.bnf`):

```bnf
<tuple> ::= \( <body> \) | \( \)
<body>  ::= <elem> <num> | <elem>
<elem>  ::= <num> , <elem> | <num> ,
<num>   ::= <dig> <num> | <dig>
<dig>   ::= [0-9]
```

Test if an input sequence matches the above grammar with:

```
echo -n "(12,34,)" | python3 -m bnf tuple.bnf
```

The printed result should be `True` or `False` whether
the input sequence is accepted by the grammar, or not, respectively.

Note: input sequence must not contain a newline (`\n`) if grammar does not support it (use `echo -n`)

Use the environment `DEBUG=1` for a verbose output
(`DEBUG=2` for a more verbose output):

```
echo -n "(12,34,)" | DEBUG=1 python3 -m bnf tuple.bnf
```

In interactive mode:
```
>>> from bnf import grammar, parse
>>> grammar("<tuple> ::= \( <body> \) | \( \)\n<body>  ::= <elem> <num> | <elem>\n<elem>  ::= <num> , <elem> | <num> ,\n<num>   ::= <dig> <num> | <dig>\n<dig>   ::= [0-9]\n")
>>> parse("(12,34,)")
```

EBNF syntax:
============

1. terminal symbols must be quoted between `""`: `"if"`
2. rules end with `;` not a newline

remaining rules are the same as for BNF syntax.

The tuple example in eBNF becomes (`tuple.ebnf`):

```bnf
tuple ::= '(' body ')' | '(' ')' ;
body  ::= elem num | elem ;
elem  ::= num ',' elem | num ',' ;
num   ::= dig num | dig ;
dig   ::= [0-9] ;
```

Test if an input sequence matches the above grammar with:

```
echo -n "(12,34,)" | python3 -m ebnf tuple.ebnf
```

In interactive mode:
```
>>> from ebnf import grammar, parse
>>> grammar("tuple ::= '(' body ')' | '(' ')' ;body  ::= elem num | elem ;elem  ::= num ',' elem | num ',' ;num   ::= dig num | dig ;dig   ::= [0-9] ;")
>>> parse("(12,34,)")
```

The bnf/ package includes:
==========================

* bnf.py: BNF parser and input sequence scanner
* ebnf.py: extended BNF parser and input sequence scanner

Documentation in the docs/ directory:

* tutorial.html: an introduction guide
* internals.html: bnf/ebnf routine description

Code examples:

* exs/: some demonstration examples

(C) prs, IST 2022
parser-ci-AP 0.1.40
C code parser based on Clang
License: MIT
Requires Python: >=3.13

# Parser CI — C Parser на базе Clang

Инструмент для анализа C-проектов. Работает на базе libclang. Извлекает полезную информацию из исходников: функции, переменные, типы, макросы и контекст.

## Возможности

### 🔧 На уровне проекта:
1. Перечислить все пользовательские типы данных (структуры, перечисления, typedef и т.д.)
2. Перечислить все файлы проекта
3. Подсчитать количество строк (всего / без комментариев / только функциональных)
4. Перечислить все define-ы (макросы)
5. Перечислить все глобальные, static и extern переменные
6. Перечислить все функции (глобальные и static отдельно)
7. Разделить define-ы на системные и пользовательские

### 📄 На уровне файла:
1. Перечислить все функции в файле
2. Перечислить все зависимости (#include)
3. Все переменные (глобальные, static, extern)
4. Все define-ы
5. Все пользовательские типы
6. Подсчёт строк (всего / только функциональных)
7. Диагностика кода (clang diagnostics)

### 🔁 На уровне функции:
1. Аргументы и локальные переменные
2. Имя, шапка, возвращаемый тип и значение
3. Используемые глобальные переменные
4. Вызовы других функций
5. Кол-во строк кода
6. Извлечение контекста для изолированной компиляции

## Установка

```bash
pip install parser-ci-AP
```

## Пример использования
```python
from parser_ci import Project
project = Project(Path(r"\path\to\c\project"))
for f in pr.global_functions:
    print(f.name)
```

## Структура проекта
```bash
parser-ci/
├── parser_ci_AP/
│   ├── __init__.py
│   ├── define_info.py
│   ├── errors_info.py
│   ├── function_info.py
│   ├── logger.py
│   ├── project.py
│   ├── project_file.py
│   ├── type_info.py
│   └── variable_info.py
├── README.md
├── setup.py
├── LICENSE
```
pyburg-pkg-peresan 1.4.1
A BURG (Bottom-Up Rewrite Grammar) instruction selection compiler generator
License: MIT
Requires Python: >=3.6

A BURG (Bottom-Up Rewrite Grammar) instruction selection generator compiler

The pyburg/ package includes:
* pyburg.py: instruction selection tool
* brg2py.py: converter from pburg (C, java) to pyburg (python)
* postfix.py: macros for assembly generation: x86, amd64, arm32, i386, ...
* Tree.py: simple binary tree for AST building
* strbuf.py: class to collect output into a string

Documentation in the docs/ directory:
* pyburg.html: instruction selection with pyburg
* tutorial.html: a complete example
* internals.html: pyburg routine description
* postfix.html: assembly macros description

Code generation examples:
* exs: some demonstration examples
* add: a trivial language implementation
* simple: a simple language implementation
* bpl: B programming language implementation
* run: x64 runtime for the above examples

(C) prs, IST 2020
album-package 0.5.0
album plugin to package solutions into executable install wizards
License: MIT
Requires Python: >=3.7
Keywords: virtual, environments, imaging, data analysis, packaging

# Album plugin for packaging solutions into executables

This plugin is used to create installation executables for Album and Album solutions, so Album and a solution can be
installed with a simple double click. The executable creates a shortcut for running Albums UI on the desktop of the
user. The executables can be distributed to a different system running the same operating system. To create executables
for different operating systems, run this plugin on a system running the target operating system. If the the target
system runs Windows or MacOS it doesn't need to have anything preinstalled, the executable will install every needed
component (Micromamba and album) into the ~/.album directory if they are not already installed in this location. Linux users
need to have the binutils package installed.

## Installation:

1. [Install Album](https://docs.album.solutions/en/latest/installation-instructions.html#)
2. Activate the album environment:

```
conda activate album
```

3. Install the album package plugin:

```
pip install album-package
```

4. If you are using a linux system, make sure the source and the target system got the binutils package installed. For
   example on ubuntu it can be installed with the following command:

```
apt-get update && apt-get install binutils
```

## Usage:

To create an executable which installs Album run following command:

```
album package --output_path /your/output/path
```

To create an executable which installs Album and a solution in one go run following command:

```
album package --solution /path/to/your/solution.py --output_path /your/output/path
```


### Input parameter:

- solution: The album solution.py file which should be packed into an executable.
  If you provide the path to a directory containing a solution.py all files in the directory will be packaged into the
  solution executable. If you provide the direct path to a solution.py only the solution will packaged. If your solution
  contains local imports, make sure all imported files lie in the same directory as the solution and you provide the
  path containing the solution.py. If this parameter is not set, the resulting executable will only install Album without
  a solution. 
- output_path: The path where the executable should be saved
beecol 0.1.0
A simple Artificial Bee Colony (ABC) library for Python.
License: MIT
Requires Python: >=3.6

# :bee: beecol

A simple Artificial Bee Colony (ABC) algorithm library for Python.

## Features

- Pure Python implementation of the Artificial Bee Colony (ABC) algorithm
- Simple API for continuous optimization problems
- Easily extensible and customizable
- Only dependency: `numpy`

## Installation

```bash
pip install beecol
```

Or clone this repository and use locally:

```bash
git clone https://github.com/atasoglu/beecol.git
cd beecol
pip install .
```

## Usage

```python
import numpy as np
from beecol import ArtificialBeeColony

# Define your fitness function (to maximize)
def fit_func(x):
    # Example: Sphere function (min at 0, but ABC maximizes, so use negative)
    return -np.sum(x**2)

# Set up the optimizer
abc = ArtificialBeeColony(
    fit_func=fit_func,
    dim=5,                # Number of parameters
    bounds=(-5, 5),       # Search space bounds
    n_bees=20,            # Number of bees (food sources)
)

# Run optimization
for i in range(100):
    best_solution, best_fitness = abc.step()
    print(f"Iteration {i}: Best fitness = {best_fitness}")

print("Best solution found:", best_solution)
```

### Example: Knapsack Problem

A full example is provided in [`examples/knapsack.py`](examples/knapsack.py), including plotting and a custom fitness function for the 0/1 knapsack problem.

To run:

```bash
cd examples
python knapsack.py
```

## Citation

- Karaboga, D., & Basturk, B. (2007). *A powerful and efficient algorithm for numerical function optimization: artificial bee colony (ABC) algorithm*. Journal of Global Optimization, 39(3), 459–471.
- Karaboga, D., & Basturk, B. (2007). *Artificial Bee Colony (ABC) optimization algorithm for solving constrained optimization problems*. In *Foundations of Fuzzy Logic and Soft Computing*, LNCS 4529, 789–798.


## Contributing

Contributions are welcome! Feel free to open issues or submit pull requests to help improve pygena.

## License

MIT