semvec/pypi-packages huggingface dataset:
tree-sitter-iml 0.26.0
IML (Imandra Modeling Language) grammar for tree-sitter
Requires Python: >=3.10
Keywords: incremental, parsing, tree-sitter, iml

# tree-sitter-iml

This module provides [IML (Imandra Modeling Language)](https://docs.imandra.ai/imandrax/) grammars for the [tree-sitter][] parsing library. It's based on the [tree-sitter-ocaml](https://github.com/tree-sitter/tree-sitter-ocaml) grammar.

## Installation

```sh
pip install tree-sitter-iml
```

You will probably also need the [tree-sitter binding][tree-sitter binding].

```sh
pip install tree-sitter
```

## Usage

Load the grammar as a `Language` object:

```python
import tree_sitter_iml
from tree_sitter import Language, Parser

language_iml = Language(tree_sitter_iml.language_iml())
```

Create a `Parser` and configure it to use the language:

```python
parser = Parser(language_iml)
```

Parse some source code:

```python
tree = parser.parse(iml_code)
```

Use `language_iml()` for IML files, `language_ocaml()` for OCaml files,
`language_ocaml_interface()` to parse interface files (with `.mli` extension),
and `language_ocaml_type()` to parse type signatures.
bt1337xearch 0.2.0
Better search for 1337x[.]to with basic filters
Requires Python: >=3.14

# bt1337xearch
Better search for 1337x[.]to with basic filters

## What it does
bt1337xearch is a command-line tool that searches 1337x.to torrents with:
- Category filtering (Movies, TV, Games, etc.)
- Sorting options (by time, size, seeders, leechers)
- Keyword filtering (include/exclude keywords)

## Prerequisites
bt1337xearch uses scrapling StealthyFetcher for bypassing the Cloudflare Captcha. \
The StealthyFetcher uses a custom playwrigth build to made that happen. \
You can install this playwright version using Scrapling:

```bash
uv tool install scrapling
scrapling install
```

## Installation
```bash
uv tool install bt1337xearch
```
or
```bash
git clone https://github.com/SimoneFelici/bt1337xearch.git
cd bt1337xearch
uv tool install .
```

## Usage

### Basic search (Probably broken)
```bash
bt1337xearch -n "Dexter"
```

### Search with category (Recommended)
```bash
bt1337xearch -n "Lupin" -c ANIME
```

### Search with sorting
```bash
bt1337xearch -n "Alien" -c MOVIE -s TIME -o DESC
```

### Advanced filtering
Use `+` to include words and `~` to exclude words:
```bash
# Include only results with "1080p" or "BluRay"
bt1337xearch -n "Dexter" -f +1080p +BluRay

# Exclude results with "CAM" or "TS"
bt1337xearch -n "Movie" -f ~CAM ~TS

# Combine include and exclude
bt1337xearch -n "Dexter" -c TV -f +1080p "~x265 HEVC" ~CAM
```

## Options

| Option | Description | Choices |
|--------|-------------|---------|
| `-n, --name` | Name of the media (required) | - |
| `-c, --category` | Filter by category | MOVIE, TV, GAME, MUSIC, APP, DOCU, ANIME, OTHER, XXX |
| `-s, --sort` | Sort results by | TIME, SIZE, SEED, LEECH |
| `-o, --order` | Sort order (default: DESC) | ASC, DESC |
| `-f, --filter` | Filter by keywords | Use `+word` to include, `~word` to exclude |

## Examples
```bash
# Search for Dexter TV series, sorted by seeders
bt1337xearch -n Dexter -c TV -s SEED

# Search for movies with "1080p", exclude "CAM" releases
bt1337xearch -n "Angel's Egg" -c MOVIE -s TIME -o DESC -f +1080p '~CAM'

# Search for games, sorted by upload time
bt1337xearch -n "Peak" -c GAME -s TIME -o ASC
```

## Output

For each result, the tool displays:
- Name
- Seeders
- Leechers
- Upload date
- File size
- Uploader
pionir 0.1.0
A Comprehensive Python Package for Near-Infrared Spectroscopy (NIR).
Requires Python: >=3.14
Keywords: Spectroscopy, NIR, chemometrics, analytical-chemistry

# PioNIR

PioNIR is a Python library designed for the processing and analysis of near-infrared (NIR) spectra. It offers a suite of chemometric tools for preprocessing, modeling, and evaluation, facilitating the development of spectroscopy workflows. The library tightly integrates with the scientific Python ecosystem, with [NumPy](https://numpy.org), [SciPy](https://scipy.org), and [scikit-learn](https://scikit-learn.org/stable/).

## Installation

The latest release is available on PyPI and can be installed via pip.

```shell
pip install pionir
```

For development purposes, use [uv](https://docs.astral.sh/uv/) to manage the installation.

```shell
uv sync --dev
```

The project uses [ruff](https://docs.astral.sh/ruff/) for linting and formatting, [ty](https://docs.astral.sh/ty/) for type checking, and [pytest](https://docs.pytest.org/) for testing.

```shell
uvx ruff check src
uvx ty check src
uv run pytest
```

## Features

### Data Representation

PioNIR provides specialized `Spectrum` and `SpectrumCollection` classes to handle NIR spectra. These classes serve as the foundation for handling individual measurements and larger datasets within the library.

```python
from pionir import Spectrum, SpectrumCollection, Metadata

# x, y: NumPy ndarrays
s = Spectrum(x=..., y=..., metadata=...)  # Single spectrum
c = SpectrumCollection([s])  # Collection of spectra
```

### Unified Interface with Single Dispatch

PioNIR uses a single dispatch approach, allowing the same function interface to handle both individual `Spectrum` objects and `SpectrumCollection` instances as well as plain NumPy `ndarray`.

```python
from pionir import Spectrum, SpectrumCollection
from pionir.scatter import snv

s = Spectrum(...)
c = SpectrumCollection(...)

# The same function handles both single spectra and collections
s_snv = snv(s)
c_snv = snv(c)
```

### scikit-learn Integration

The library is designed for compatibility with scikit-learn, providing transformers that can be directly incorporated into pipelines.

```python
from sklearn.decomposition import PCA
from sklearn.linear_model import LinearRegression
from sklearn.pipeline import Pipeline

from pionir import SpectrumCollection
from pionir.sklearn.transformer import SNVTransformer

c = SpectrumCollection([...])

pcr_pipeline = Pipeline([
    ("snv", SNVTransformer()),
    ("pca", PCA(n_components=5)),
    ("regression", LinearRegression())
])

pcr_pipeline.fit(c.y, ...)
pcr_pipeline.predict(...)
```
openmeeg 2.5.16
Forward problems solver in the field of EEG and MEG.
Requires Python: >=3.10
Keywords: neuroscience, neuroimaging, MEG, EEG, ECoG, sEEG, iEEG, brain

OpenMEEG: forward problems solver in the field of EEG and MEG
=============================================================

The OpenMEEG software is a C++ package for solving the forward
problems of electroencephalography (EEG) and magnetoencephalography (MEG).

OpenMEEG is distributed under the French opensource license CeCILL-B. It is
intended to give users the freedom to modify and redistribute the software.
It is therefore compatible with popular opensource licenses such as the GPL
and BSD licenses. The CeCILL-B license imposes to anybody distributing a
software incorporating OpenMEEG the obligation to give credits (by citing the
appropriate publications), in order for all contributions to be properly
identified and acknowledged.

Cite this software
------------------

The references to be acknowledged are ::

    Gramfort A, Papadopoulo T, Olivi E, Clerc M. OpenMEEG: opensource software for quasistatic
    bioelectromagnetics. Biomedical engineering online (2010) vol. 9 (1) pp. 45

    Kybic J, Clerc M, Abboud T, Faugeras O, Keriven R, Papadopoulo T. Generalized head models for MEG/EEG: boundary element method
    beyond nested volumes. Phys. Med. Biol. (2006) vol. 51 pp. 1333-1346

.. image:: https://raw.githubusercontent.com/openmeeg/openmeeg.github.io/source/_static/inria.png
breezy 3.3.21
Friendly distributed version control system
Requires Python: <3.15,>=3.10

Breezy (``brz``) is a decentralized revision control system, designed to be
easy for developers and end users alike.

By default, Breezy provides support for both the `Bazaar
<https://www.bazaar-vcs.org>`_ and `Git <https://www.git-scm.com/>`_ file
formats.

You can install from source by following the instructions in the INSTALL file.
At the moment of writing there are no binary packages available.

To learn how to use Breezy, see the official documentation in the `doc`
directory or refer to the Bazaar documentation at
<https://www.breezy-vcs.org/doc/en/>.

Breezy is Free Software, and is released under the GNU General Public License,
version 2 or later.

Breezy is a friendly fork of the Bazaar (``bzr``) project, hosted on
http://bazaar.canonical.com/. It is backwards compatibility with
Bazaar's disk format and protocols. One of the key differences with
Bazaar is that Breezy runs on Python 3, rather than on Python 2.

Breezy highlights
=================

Breezy directly supports both central version control (like cvs/svn) and
distributed version control (like git/hg). Developers can organize their
workspace in whichever way they want on a per project basis including:

* checkouts (like svn)
* feature branches (like hg)
* shared working tree (like git).

It also directly supports and encourages a large number of development best
practices like refactoring and pre-commit regression testing. Users can
choose between our command line tool and our cross-platform GUI application.
For further details, see our website.

Feedback
========

If you encounter any problems with Breezy, need help understanding it, or would
like to offer suggestions or feedback, please get in touch with us:

* Ask a question through our web support interface, at
  https://answers.launchpad.net/brz/

* Report bugs at https://bugs.launchpad.net/brz/+filebug

* Write to the mailing list at bazaar@lists.canonical.com
  You can join the list at <https://lists.ubuntu.com/mailman/listinfo/bazaar>.
  You don't need to subscribe to post, but your first post will be held
  briefly for manual moderation.

  Please mention that you are using Breezy rather than Bazaar.

* Talk to us in irc://irc.oftc.net/breezy or
  `#breezy:matrix.org <https://matrix.to/#/#breezy:matrix.org>`_.

Our mission is to make a version control tool that developers LOVE to use
and that casual contributors feel confident with. Please let us know how
we're going.

The Breezy Team
mocap-settings 1.27.0
Motion capture service used for all moveai engine's operation settings.
Requires Python: <4.0,>=3.10

# mocap-settings

# Description

Motion capture service used for all moveai engine's operation settings.

# Installation

`pip install mocap-settings`

# License

A valid license is needed to run this project. Please contact [support\@move.ai](mailto:support@move.ai) or visit https://move.ai if you need a license.

# Support

Please contact support@move.ai for any technical queries.
abbrev 1.3.0
🐜 Expand abbreviations 🐜
Requires Python: >=3.10

# 🐜 `abbrev`: Expand abbreviations 🐜

Expand a `Sequence` or `Mapping` of string abbreviations.

Handy when the user has a choice of commands with long names.

## Example 1: Use a list of choices

    import abbrev

    a = ['one', 'two', 'three']

    assert abbrev(a, 'one') == 'one'
    assert abbrev(a, 'o') == 'one'
    assert abbrev(a, 'tw') == 'two'

    abbrev(a, 'four')  # Raises a KeyError: no such key
    abbrev(a, 't')  # Raises a KeyError: ambiguous key ('two' or 'three'?)


## Example 2: Use a dictionary of choices

    import abbrev

    d = {'one': 100, 'two': 200, 'three': 300}

    assert abbrev(d, 'one') == 100
    assert abbrev(d, 'o') == 100
    assert abbrev(d, 'tw') == 200

## Example 3: Make an abbreviator to re-use

    import abbrev

    d = {'one': 100, 'two': 200, 'three': 300}

    abbreviator = abbrev(d)

    assert abbreviator('one') == my_abbrevs('o') == 100
    assert abbreviator('tw') == 200

## Example 4: Get all matches, when `multi=True`

    import abbrev

    a = ['one', 'two, 'three'}

    multi = abbrev(a, multi=True)  # Make an abbreviator

    assert multi('t') == abbrev(d, 't', multi=True) == ('two', three')
    assert multi('o') == abbrev(d, 'o', multi=True) == ('one', )

    multi('four')  # Still raises a key error

## Example 5: Get only the first result, when `unique=False`

    import abbrev

    d = {'one': 100, 'two': 200, 'three': 300}

    assert abbrev(d, 't', unique=False) == (200, 300)


### [API Documentation](https://rec.github.io/abbrev#abbrev--api-documentation)
datacls 4.9.0
🗂 Take the edge off `dataclass` 🗂
Requires Python: >=3.10

# 🗂 `datacls`: take the edge off `dataclass` 🗂

`dataclasses` is almost perfect.

`datacls` is a tiny, thin wrapper around `dataclass.dataclasses` making it
a bit more self-contained, reflective, and saving a bit of typing.

`datacls` is exactly like `dataclass`, except:

  * Adds three new instance methods: `asdict()`, `astuple()`, `replace()`,
    and one new class method, `fields()`, all taken from the `dataclasses`
    module

  * `xmod`-ed for less cruft (so `datacls` is the same as `datacls.dataclass`)

  * The default class is `datacls.immutable` where `frozen=True`.

## Example

    import datacls

    @datacls
    class One:
        one: str = 'one'
        two: int = 2
        three: dict = datacls.field(dict)

    # `One` has three instance methods: asdict(), astuple(), replace()

    o = One()
    assert o.asdict() == {'one': 'one', 'two': 2, 'three': {}}

    import dataclasses
    assert dataclasses.asdict(o) == o.asdict()

    assert o.astuple() == ('one', 2, {})

    o2 = o.replace(one='seven', three={'nine': 9})
    assert o2 == One('seven', 2, {'nine': 9})

    # `One` has one new class method: fields()

    assert [f.name for f in One.fields()] == ['one', 'two', 'three']

    # @datacls is immutable.

    try:
        o.one = 'three'
    except AttributeError:
        pass
    else:
        raise AttributeError('Was mutable!')

    # Usec @datacls.mutable or @datacls(frozen=False)
    # for mutable classes

    @datacls.mutable
    class OneMutable:
        one: str = 'one'
        two: int = 2
        three: Dict = datacls.field(dict)

    om = OneMutable()
    om.one = 'three'
    assert str(om) == "OneMutable(one='three', two=2, three={})"

    # These four new methods won't break your old dataclass by mistake:
    @datacls
    class Overloads:
        one: str = 'one'
        asdict: int = 1
        astuple: int = 1
        fields: int = 1
        replace: int = 1

    o = Overloads()

    assert ov.one == 'one'
    assert ov.asdict == 1
    assert ov.astuple == 1
    assert ov.fields == 1
    assert ov.replace == 1

    # You can still access the methods as functions on `datacls`:
    assert (
        datacls.asdict(ov) ==
        {'asdict': 1, 'astuple': 1, 'fields': 1, 'one': 'one', 'replace': 1}
    )


### [API Documentation](https://rec.github.io/datacls#datacls--api-documentation)
impall 1.6.0
🛎 Test-import all modules 🛎
Requires Python: >=3.10

# 🛎 Test-import all modules 🛎

Individually and separately imports each Python module or file in a project and
reports warnings or failures at the end.

### Running impall as a unit test

Just inherit from the base class and it will
automatically find and import each file, like this.

    import impall

    class ImpAllTest(impall.ImpAllTest):
        pass

(You can copy
[this file](https://github.com/rec/impall/blob/master/all_test.py)
into your project if you like.)

Tests are customized by overriding one of these following properties in the
derived class.

    CLEAR_SYS_MODULES, EXCLUDE, FAILING, INCLUDE, MODULES, PATHS,
    RAISE_EXCEPTIONS, and WARNINGS_ACTION.

For example, to turn warnings into errors, set the property
WARNINGS_ACTION in the derived class definition, like this.

    class ImpAllTest(impall.ImpAllTest):
        WARNINGS_ACTION = 'error'

## Running impall as a command-line utility

    $ impall --warnings_action=error
    $ impall -w error

The properties INCLUDE, EXCLUDE, and PROJECT_PATH can be
lists of strings, or a string separated with colons like
'foo.mod1:foo.mod2'

INCLUDE and EXCLUDE match modules, and also allow * as a wildcard.
A single * matches any module segment, and a double ** matches any
remaining segments. For example,

`INCLUDE = 'foo', 'bar.*', 'baz.**'`

* matches `foo` but not `foo.foo`
* matches `bar.foo` but not `bar` or `bar.foo.bar`
* matches `baz.foo` as well as `baz.foo.bar` but not `baz`

### A note on side-effects

to reduce side-effects, `sys.modules` is restored to its original
condition after each import if CLEAR_SYS_MODULES is true, but there might be
other side-effects from loading some specific module.

Use the EXCLUDE property to exclude modules with undesirable side
effects. In general, it is probably a bad idea to have significant
side-effects just from loading a module.

### [API Documentation](https://rec.github.io/impall#impall--api-documentation)
xmod 1.9.0
🌱 Turn any object into a module 🌱
Requires Python: >=3.10

# 🌱 Turn any object into a module 🌱

Callable modules!  Indexable modules!?

Ever wanted to call a module directly, or index it?  Or just sick of seeing
`from foo import foo` in your examples?

Give your module the awesome power of an object, or maybe just save a
little typing, with `xmod`.

`xmod` is a tiny library that lets a module to do things that normally
only a class could do - handy for modules that "just do one thing".

## Example: Make a module callable like a function!

    # In your_module.py
    import xmod

    @xmod
    def a_function():
        return 'HERE!!'


    # Test at the command line
    >>> import your_module
    >>> your_module()
    HERE!!

## Example: Make a module look like a list!?!

    # In your_module.py
    import xmod

    xmod(list(), __name__)

    # Test at the command line
    >>> import your_module
    >>> assert your_module == []
    >>> your_module.extend(range(3))
    >>> print(your_module)
    [0, 1, 2]


### [API Documentation](https://rec.github.io/xmod#xmod--api-documentation)
fil 1.5.0
🏺 Read/write JSON/TOML/Yaml/txt 🏺
Requires Python: >=3.10

## Example 1: read a file

    d1 = fil.read('file.json')   # Any Json
    d2 = fil.read('file.toml')   # A dict
    d3 = fil.read('file.yaml')   # Any JSON
    d4 = fil.read('file.txt')    # A string

    # Reading a JSON Line file returns an interator:
    for record in fil.read('file.jsonl'):
        print(record)  # A sequence of JSON

## Example 2: write to a file

    fil.write(d1, 'file.json')  # d1 can be any JSON
    fil.write(d2, 'file.toml')  # d2 must be a dict
    fil.write(d3, 'file.yaml')  # d3 can be any JSON
    fil.write(d4, 'file.txt')   # d4 most be a str

    # Write an iterator to a JSON Line file
    dicts = ({'key': i} for i in range(10))
    fil.write(dicts, 'file.jsonl')


### [API Documentation](https://rec.github.io/fil#fil--api-documentation)
sproc 2.5.0
⛏ Subprocesseses for subhumanses ⛏
Requires Python: >=3.10

# ⛏️sproc: subprocesseses for subhumanses  ⛏

Run a command in a subprocess and yield lines of text from `stdout` and
`stderr` independently.

Useful for handling long-running proceesses that write to both `stdout` and
`stderr`.

### Simple Example

    import sproc

    CMD = 'my-unix-command "My Cool File.txt" No-file.txt'

    for ok, line in sproc.Sub(CMD) as sp:
        if ok:
             print(' ', line)
        else:
             print('!', line)

    if sp.returncode:
        print('Error code', sp.returncode)

    # Return two lists of text lines and a returncode
    out_lines, err_lines, returncode = sproc.run(CMD)

    # Call callback functions with lines of text read from stdout and stderr
    returncode = sproc.call(CMD, save_results, print_errors)

    # Log stdout and stderr, with prefixes
    returncode = sproc.log(CMD)


### [API Documentation](https://rec.github.io/sproc#sproc--api-documentation)
clsprop 1.4.0
🏫 Just like @property but for classes 🏫
Requires Python: >=3.10

Works just like @property for classes, except deleters don't work (and are
perhaps impossible).

Inspired by https://stackoverflow.com/a/39542816/43839

## Example

    import clsprop

    class Full:
        _name = 'fool'

        @clsprop
        def name(cls):
            return cls._name

        @name.setter
        def name(cls, name):
            cls._name = name

        # Unfortunately, the deleter never gets called
        @name.deleter
        def name(cls, name):
            raise ValueError('Cannot delete name')

    assert Full.name == 'fool'

    Full.name = 'foll'
    assert Full.name == 'foll'

    del Full.name  # oh, well


### [API Documentation](https://rec.github.io/clsprop#clsprop--api-documentation)
nc 1.1.0
🎨 Named colors in Python 🎨
Requires Python: >=3.10

# 🎨 `nc`: Named colors in Python 🎨

--

The module `nc` collects named colors in Python.

There are two ways to use `nc`.

The simple way is as an intuitive and forgiving interface to a
collection of over 2000 named colors, put together from almost 20 color
palettes scraped from the Internet.

In the simplest use, it's a collection of about 1700 colors, some
scraped from the Wikipedia (which includes some very strange colors),
with a neat API.

For more precise use, color collections can be put together from schemes
built into `nc` (currently `html`, `juce`, `pwg`, `wikipedia`, `x11`),
or from custom color schemes created by the user.

There is also a collection of [color swatches](swatches/) for the default
color collection.

# Examples

    import nc

    for c in nc.red, nc.light_green, nc.DarkGrey, nc['PUCE']:
        print(c, '=', *c)

    # Prints:
    #   Red = 255 0 0
    #   Light green = 144 238 144
    #   Dark grey = 85 85 85
    #   Puce = 204 136 153

    # Colors have red, green, blue or r, g, b components
    assert nc.yellow.red == nc.yellow.r == 0
    assert nc.yellow.green == nc.yellow.g == 255
    assert nc.yellow.blue == nc.yellow.b == 255

    # Lots of ways to reach colors
    assert nc.black == nc(0, 0, 0) == nc('0, 0, 0') == nc('(0, 0, 0)') == nc(0)

    # ``nc`` looks like a dict
    assert nc.red == nc['red'] == nc['RED']
    for name, color in nc.items():
        print(name, '=', *color)

    # Prints:
    #   Absolute Zero = 0 72 186
    #   Acid green = 176 191 26
    #   Aero = 124 185 232
    #   ... many more

    # closest() function

    from random import randrange
    for i in range(8):
        c1 = randrange(256), randrange(256), randrange(256)
        c2 = nc.closest(c1)
        print(c1, 'is closest to', c2, *c2)

    # Prints:
    #   (193, 207, 185) is closest to Honeydew 3 = 193 205 193
    #   (181, 162, 188) is closest to Lilac = 200 162 200
    #   (122, 110, 250) is closest to Slate blue 1 = 131 111 255
    #   (56, 218, 180) is closest to Turquoise = 64 224 208


### [API Documentation](https://rec.github.io/nc#nc--api-documentation)