Skip to content

lenna-project/lenna-cli

main
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

lenna-cli

lenna-cli Crates.io dependency status

Lenna is a library for image processing algorithms and apps.

This is the Command Line Interface for Lenna based on lenna_core.

asciicast

Lenna CLI

🐰 quickstart

cargo build

✂️ copy plugins

Here are some plugins. After the plugins are built, they can be copied and used with lenne-cli.

mkdir plugins
cp ../lenna-plugins/target/release/lib*.so plugins/

🔧 config

Create a file called lenna.yml.

pipeline:
  - id: resize
    width: 500
    height: 500
  - id: canny
    low: 50.0
    high: 100.0
  - id: blur
    sigma: 1.5

Id is the plugin, the other attributes are the parameter for the plugin.

👻 run

cargo run --features="libloading" -- lenna.png -o lenna_out.png -c lenna.yml

Run

install

Install using snapcraft.

snapcraft
sudo snap install lenna-cli_*.snap --devmode --dangerous
lenna-cli --help
lenna-cli lenna.png --config lenna.yml --output out.png --plugins /snap/lenna-cli/current/plugins

🐍 build python bindings

Create a virtual environment for python and install lenna-cli using pip.

virtualenv -p python3 .venv
source .venv/bin/activate
pip install .
python src/python/test.py
import lenna_cli
lennaCli = lenna_cli.LennaCli()
print(lennaCli.plugins())

jupyter

You can test the python bindings in a jupyter notebook.

📜 License

This software is licensed under the MIT © lenna-project.

About

Command Line Interface for Lenna

Resources

License

Stars

Watchers

Forks

Packages

No packages published