image-processing-tiagofiorilli 0.0.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- image_processing_tiagofiorilli-0.0.5/PKG-INFO +32 -0
- image_processing_tiagofiorilli-0.0.5/README.md +13 -0
- image_processing_tiagofiorilli-0.0.5/image_processing/__init__.py +0 -0
- image_processing_tiagofiorilli-0.0.5/image_processing/processing/__init__.py +0 -0
- image_processing_tiagofiorilli-0.0.5/image_processing/processing/combination.py +17 -0
- image_processing_tiagofiorilli-0.0.5/image_processing/processing/transformation.py +8 -0
- image_processing_tiagofiorilli-0.0.5/image_processing/utils/__init__.py +0 -0
- image_processing_tiagofiorilli-0.0.5/image_processing/utils/io.py +8 -0
- image_processing_tiagofiorilli-0.0.5/image_processing/utils/plot.py +28 -0
- image_processing_tiagofiorilli-0.0.5/image_processing_tiagofiorilli.egg-info/PKG-INFO +32 -0
- image_processing_tiagofiorilli-0.0.5/image_processing_tiagofiorilli.egg-info/SOURCES.txt +14 -0
- image_processing_tiagofiorilli-0.0.5/image_processing_tiagofiorilli.egg-info/dependency_links.txt +1 -0
- image_processing_tiagofiorilli-0.0.5/image_processing_tiagofiorilli.egg-info/requires.txt +3 -0
- image_processing_tiagofiorilli-0.0.5/image_processing_tiagofiorilli.egg-info/top_level.txt +1 -0
- image_processing_tiagofiorilli-0.0.5/setup.cfg +4 -0
- image_processing_tiagofiorilli-0.0.5/setup.py +20 -0
@@ -0,0 +1,32 @@
|
|
1
|
+
Metadata-Version: 2.4
|
2
|
+
Name: image_processing_tiagofiorilli
|
3
|
+
Version: 0.0.5
|
4
|
+
Summary: Image Processing Package using skimage
|
5
|
+
Home-page: https://github.com/tiagofiorilli/image_processing_package
|
6
|
+
Author: Tiago Fiorilli
|
7
|
+
Requires-Python: >=3.6
|
8
|
+
Description-Content-Type: text/markdown
|
9
|
+
Requires-Dist: numpy
|
10
|
+
Requires-Dist: matplotlib
|
11
|
+
Requires-Dist: scikit-image
|
12
|
+
Dynamic: author
|
13
|
+
Dynamic: description
|
14
|
+
Dynamic: description-content-type
|
15
|
+
Dynamic: home-page
|
16
|
+
Dynamic: requires-dist
|
17
|
+
Dynamic: requires-python
|
18
|
+
Dynamic: summary
|
19
|
+
|
20
|
+
# image_processing
|
21
|
+
|
22
|
+
### Descrição
|
23
|
+
O pacote `image_processing` é usado para:
|
24
|
+
- Leitura e salvamento de imagens
|
25
|
+
- Ajuste de tamanho (resize)
|
26
|
+
- Combinação e comparação
|
27
|
+
- Plotagem e histogramas
|
28
|
+
|
29
|
+
### Instalação
|
30
|
+
Para instalar o pacote localmente:
|
31
|
+
```bash
|
32
|
+
pip install .
|
@@ -0,0 +1,13 @@
|
|
1
|
+
# image_processing
|
2
|
+
|
3
|
+
### Descrição
|
4
|
+
O pacote `image_processing` é usado para:
|
5
|
+
- Leitura e salvamento de imagens
|
6
|
+
- Ajuste de tamanho (resize)
|
7
|
+
- Combinação e comparação
|
8
|
+
- Plotagem e histogramas
|
9
|
+
|
10
|
+
### Instalação
|
11
|
+
Para instalar o pacote localmente:
|
12
|
+
```bash
|
13
|
+
pip install .
|
File without changes
|
File without changes
|
@@ -0,0 +1,17 @@
|
|
1
|
+
import numpy as np
|
2
|
+
from skimage.color import rgb2gray
|
3
|
+
from skimage.exposure import match_histograms
|
4
|
+
from skimage.metrics import structutal_similarity
|
5
|
+
|
6
|
+
def find_difference(image1, image2):
|
7
|
+
asser image1.shape == image2.shape, "Specify 2 images with de same shape"
|
8
|
+
gray_image1 = rgb2gray(image1)
|
9
|
+
gray_image2 = rgb2gray(image2)
|
10
|
+
(score,difference_image) = structutal_similarity(gray_image1, gray_image2, full=True)
|
11
|
+
print("Similarity of the images:", score)
|
12
|
+
normalized_difference_image = (difference_image-np.min(difference_image))/(np.max(difference_image)-np.min(difference_image))
|
13
|
+
return normalized_difference_image
|
14
|
+
|
15
|
+
def transfer_histogram(image1,image2):
|
16
|
+
matched_image = match_histograms((image1,image2), multichannel=True)
|
17
|
+
return matched_image
|
@@ -0,0 +1,8 @@
|
|
1
|
+
from skimage.transform import resize
|
2
|
+
|
3
|
+
def resize_image(image, proportion):
|
4
|
+
assert 0 < proportion <= 1, "Specify a valid proportion between 0 and 1."
|
5
|
+
height = round(image.shape[0] * proportion)
|
6
|
+
width = round(image.shape[1] * proportion)
|
7
|
+
image_resized = resize(image, (height, width), anti_aliasing=True)
|
8
|
+
return image_resized
|
File without changes
|
@@ -0,0 +1,28 @@
|
|
1
|
+
import matplotlib.pyplot as plt
|
2
|
+
|
3
|
+
def plot_image(image):
|
4
|
+
plt.figure(figsize=(12, 4))
|
5
|
+
plt.imshow(image, cmap='gray')
|
6
|
+
plt.axis('off')
|
7
|
+
plt.show()
|
8
|
+
|
9
|
+
def plot_result(*args):
|
10
|
+
number_images = len(args)
|
11
|
+
fig, axis = plt.subplots(nrows=1, ncols=number_images, figsize=(12, 4))
|
12
|
+
names_lst = ['Image {}'.format(i) for i in range(1, number_images)]
|
13
|
+
names_lst.append('Result')
|
14
|
+
for ax, name, image in zip(axis, names_lst, args):
|
15
|
+
ax.set_title(name)
|
16
|
+
ax.imshow(image, cmap='gray')
|
17
|
+
ax.axis('off')
|
18
|
+
fig.tight_layout()
|
19
|
+
plt.show()
|
20
|
+
|
21
|
+
def plot_histogram(image):
|
22
|
+
fig, axis = plt.subplots(nrows=1, ncols=3, figsize=(12, 4), sharex=True, sharey=True)
|
23
|
+
color_lst = ['red', 'green', 'blue']
|
24
|
+
for index, (ax, color) in enumerate(zip(axis, color_lst)):
|
25
|
+
ax.set_title('{} histogram'.format(color.title()))
|
26
|
+
ax.hist(image[:, :, index].rave(), bins = 256, color = color, alpha = 0.8)
|
27
|
+
fig.tight_layout()
|
28
|
+
plt.show()
|
@@ -0,0 +1,32 @@
|
|
1
|
+
Metadata-Version: 2.4
|
2
|
+
Name: image_processing_tiagofiorilli
|
3
|
+
Version: 0.0.5
|
4
|
+
Summary: Image Processing Package using skimage
|
5
|
+
Home-page: https://github.com/tiagofiorilli/image_processing_package
|
6
|
+
Author: Tiago Fiorilli
|
7
|
+
Requires-Python: >=3.6
|
8
|
+
Description-Content-Type: text/markdown
|
9
|
+
Requires-Dist: numpy
|
10
|
+
Requires-Dist: matplotlib
|
11
|
+
Requires-Dist: scikit-image
|
12
|
+
Dynamic: author
|
13
|
+
Dynamic: description
|
14
|
+
Dynamic: description-content-type
|
15
|
+
Dynamic: home-page
|
16
|
+
Dynamic: requires-dist
|
17
|
+
Dynamic: requires-python
|
18
|
+
Dynamic: summary
|
19
|
+
|
20
|
+
# image_processing
|
21
|
+
|
22
|
+
### Descrição
|
23
|
+
O pacote `image_processing` é usado para:
|
24
|
+
- Leitura e salvamento de imagens
|
25
|
+
- Ajuste de tamanho (resize)
|
26
|
+
- Combinação e comparação
|
27
|
+
- Plotagem e histogramas
|
28
|
+
|
29
|
+
### Instalação
|
30
|
+
Para instalar o pacote localmente:
|
31
|
+
```bash
|
32
|
+
pip install .
|
@@ -0,0 +1,14 @@
|
|
1
|
+
README.md
|
2
|
+
setup.py
|
3
|
+
image_processing/__init__.py
|
4
|
+
image_processing/processing/__init__.py
|
5
|
+
image_processing/processing/combination.py
|
6
|
+
image_processing/processing/transformation.py
|
7
|
+
image_processing/utils/__init__.py
|
8
|
+
image_processing/utils/io.py
|
9
|
+
image_processing/utils/plot.py
|
10
|
+
image_processing_tiagofiorilli.egg-info/PKG-INFO
|
11
|
+
image_processing_tiagofiorilli.egg-info/SOURCES.txt
|
12
|
+
image_processing_tiagofiorilli.egg-info/dependency_links.txt
|
13
|
+
image_processing_tiagofiorilli.egg-info/requires.txt
|
14
|
+
image_processing_tiagofiorilli.egg-info/top_level.txt
|
image_processing_tiagofiorilli-0.0.5/image_processing_tiagofiorilli.egg-info/dependency_links.txt
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
|
@@ -0,0 +1 @@
|
|
1
|
+
image_processing
|
@@ -0,0 +1,20 @@
|
|
1
|
+
from setuptools import setup, find_packages
|
2
|
+
|
3
|
+
with open("README.md", "r", encoding="utf-8") as f:
|
4
|
+
page_description = f.read()
|
5
|
+
|
6
|
+
with open("requirements.txt", "r", encoding="utf-8") as f:
|
7
|
+
requirements = f.read().splitlines()
|
8
|
+
|
9
|
+
setup(
|
10
|
+
name="image_processing_tiagofiorilli",
|
11
|
+
version="0.0.5",
|
12
|
+
author="Tiago Fiorilli",
|
13
|
+
description="Image Processing Package using skimage",
|
14
|
+
long_description=page_description,
|
15
|
+
long_description_content_type="text/markdown",
|
16
|
+
url="https://github.com/tiagofiorilli/image_processing_package",
|
17
|
+
packages=find_packages(),
|
18
|
+
install_requires=requirements,
|
19
|
+
python_requires=">=3.6",
|
20
|
+
)
|