Giter VIP home page Giter VIP logo

pepeline-rs's Introduction

pypl

git

pepeline-rs

Fast rust-python librarian for internal needs of an organization

from pepeline import screentone, fast_color_level, read, save, cvt_color, CvtType
img = read(<"img path">, 0, 0)
img = fast_color_level(
    img,     
    in_low = 10,
    in_high = 240,
    out_low = 0,
    out_high = 255,
    gamma = 1.0
)
img = cvt_color(img, CvtType.RGB2CMYK)
img[:, :, 0] = screenton(img[:, :, 0], dot_size=7, angle=-15)
img[:, :, 1] = screenton(img[:, :, 1], dot_size=7, angle=0)
img[:, :, 2] = screenton(img[:, :, 2], dot_size=7, angle=15)
img[:, :, 3] = screenton(img[:, :, 3], dot_size=7, angle=30)
img = cvt_color(img, CvtType.CMYK2RGB)
save(img, "out.png")

TODO:

  • resize❓
  • documentation ♻️
  • refactoring ♻️
  • add tests ♻️
  • add benchmarks scripts ♻️
  • simd ❓

Function:

  • read - read img (supports psd)
  • screentone - add screenton patern.
  • fast_color_level - color levels correction
  • noise_generate - ganerate noise array
  • save - fast save image
  • cvt_color - converts color extensions, currently only supports f32 and in some places 0-1

pepeline-rs's People

Contributors

umzi2 avatar sekiju avatar

Stargazers

AthK avatar

pepeline-rs's Issues

error save

5
2222
after some degradation, the image is strangely preserved

save error

thread '' panicked at src/utils/image/decode.rs:306:30:
range end index 4 out of range for slice of length 0
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.