GithubHelp home page GithubHelp logo

wyhlaowang / enlarge_images_locally Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 8.88 MB

This script enlarges images locally, supporting simultaneous processing of multiple images, arbitrary zoom ratios, and placement of the magnified area in any corner of the image.

Python 100.00%

enlarge_images_locally's Introduction

图像局部放大脚本

可对图像进行局部放大,并对放大区域绘制矩形框,支持同时处理多张图像、任意放大倍率,并且可以将放大区域放置在图像的任何角落。

特点

  • 同时处理: 支持同时处理多张图像。
  • 任意放大倍率: 允许用户指定任意的放大倍率。
  • 灵活的放置: 支持将放大区域放置在图像任意角落。

用法

  1. 确保已经安装pythonopencv-python
  2. 将需要画框的图像都放入同一文件夹
  3. 设置脚本的参数
directory: (your_image_path)
save_subdir: (save_folder)
scale_factor: (enlarge_ratio) 
loacte: (location_of_patch)
  1. 运行 python draw_box_scale.py

只画矩形框

如果只需要在图像上绘制矩形框,运行```python draw_box.py```即可。

放大区域放在旁边(右面或下面)

如果只需要在图像上绘制矩形框,运行```python draw_box_side.py```即可。

单独保存放大区域

源图像

单独保存的放大区域
如果只需要在图像上绘制矩形框,运行```python draw_box_save.py```即可。

enlarge_images_locally's People

Contributors

wyhlaowang avatar

Stargazers

Nougat avatar

Watchers

 avatar

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.