A library wrapping libffm
Project description
pylibffm
pylibffm is a wrapper around libffm to allow using scipy and numpy arrays as input. pylibffm requires SSE and openmp.
Installing
If you're running python 3.7~3.11 on linux
pip install pylibffm
Otherwise
git clone --recurse-submodules https://github.com/Sinacam/pylibffm
cd pylibffm
make
pip install .
Currently, the distribution is incredibly hacky and cannot be pip installed from source. Windows build support is lacking, but code should be correct.
Documentation
The API consists of
trainloadModelModel.saveModel.predict
make_bintrain_with_bin
Use help or read their docstring for their usage.
Diff with libffm
To be deterministic, set openmp threads to 1. For pylibffm, do
OMP_NUM_THREADS=1 python <script>.py
For libffm, run with -s 1 (the default). This should yield identical models.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pylibffm-0.4.0.tar.gz
(543.4 kB
view details)
File details
Details for the file pylibffm-0.4.0.tar.gz.
File metadata
- Download URL: pylibffm-0.4.0.tar.gz
- Upload date:
- Size: 543.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.8.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7f10ac4dcdcb6c6b6085c953b871cd1f292303f1cc07d03419f92866697fbc0a
|
|
| MD5 |
a9a429f7a6387841f7292ab763233b67
|
|
| BLAKE2b-256 |
97d5d7a044eafd0d01a6bae5b22fe30de0a9423732d00402f5b9470a19118482
|