No project description provided
Project description
Fast Reflection Removal
Removes reflections quickly and easily.
How to use
You can either:
- install it as a Python package,
- clone and use it as a repository, or
- use it as a web app on my website.
How to install
As a package
In your own project, just perform the following command:
# python refers to the virtual environment to install package to
python -m pip install fast-reflection-removal
Now, you can use the reflection removal in your project in the following manner:
from frr import FastReflectionRemoval
...
# numpy array with values between 0 and 1 of shape (H, W, C)
img = ...
# instantiate the algoroithm class
alg = FastReflectionRemoval(h = 0.11)
# run the algorithm and get result of shape (H, W, C)
dereflected_img = alg.remove_reflection(img)
...
As a repository
- Clone the project and go to its root directory.
- Create and activate the virtual environment:
# create the environment python3 -m venv "venv" # activate the environment source venv/bin/activate # on Windows ./venv/Scripts/activate.ps1 in Powershell
- Install the necessary packages:
python -m pip install --upgrade pip python -m pip install --upgrade wheel setuptools pip-tools
- Install the packages from requirements and the project:
make sync # on windows just perform the following commands: python -m piptools sync requirements.txt; python -m pip install -e .
How to run the project
Example:
# activate the environment
source venv/bin/activate # on Windows ./venv/Scripts/activate.ps1 in Powershell
frr ".\tests\test_frr\fixtures\toy_example.jpg" "out.jpg" -h 0.11
The program, in this example, loads input image from the path .\tests\test_frr\fixtures\toy_example.jpg, processes it with parameter h=0.11 and outputs it into out.jpg. More information about the parameters can be obtained by invoking frr --help.
Project structure
Folders:
- docs: documentation.
- src: contains list of folders for sources, e.g. python.
- tests: tests that follow the structure of src/python.
Credits
This repository implements paper Fast Single Image Reflection Suppression via Convex Optimization authored by Yang Yang, Wenye Ma, Yin Zheng, Jian-Feng Cai and Weiyu Xu.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fast-reflection-removal-1.1.tar.gz.
File metadata
- Download URL: fast-reflection-removal-1.1.tar.gz
- Upload date:
- Size: 5.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7d17cb4d90b67fecbfd2c92b0a3e64312c924cf59ef92cd785634ce78937b41a
|
|
| MD5 |
7f05415bddf9af9d0722e4d50f83ff7a
|
|
| BLAKE2b-256 |
eaf8c64ea74a6d9dd8957b98671d457e47aeb4bda6d4e54ebe46e6d147d24fb5
|
File details
Details for the file fast_reflection_removal-1.1-py3-none-any.whl.
File metadata
- Download URL: fast_reflection_removal-1.1-py3-none-any.whl
- Upload date:
- Size: 6.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6ac11e7388c6b2559af61eb8d59dfc35fad1a7562206bf85ecd3f21b7cc355a1
|
|
| MD5 |
1b812dc425f08ca6e481f7ced4657180
|
|
| BLAKE2b-256 |
0602d45f20207403c7c7a15be2a1968c3d96e364109d9c879b26c7c25dd9713b
|