drap 0.0.2__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.
- drap-0.0.2/LICENSE +21 -0
- drap-0.0.2/PKG-INFO +35 -0
- drap-0.0.2/README.md +14 -0
- drap-0.0.2/pyproject.toml +32 -0
- drap-0.0.2/setup.cfg +4 -0
- drap-0.0.2/src/__init__.py +3 -0
- drap-0.0.2/src/automation.py +61 -0
- drap-0.0.2/src/drap.egg-info/PKG-INFO +35 -0
- drap-0.0.2/src/drap.egg-info/SOURCES.txt +14 -0
- drap-0.0.2/src/drap.egg-info/dependency_links.txt +1 -0
- drap-0.0.2/src/drap.egg-info/entry_points.txt +3 -0
- drap-0.0.2/src/drap.egg-info/requires.txt +7 -0
- drap-0.0.2/src/drap.egg-info/top_level.txt +5 -0
- drap-0.0.2/src/gui.py +46 -0
- drap-0.0.2/src/main.py +71 -0
- drap-0.0.2/src/terminal_interface.py +66 -0
drap-0.0.2/LICENSE
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
MIT License
|
2
|
+
|
3
|
+
Copyright (c) 2025 Cássio Alves
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the “Software”), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
drap-0.0.2/PKG-INFO
ADDED
@@ -0,0 +1,35 @@
|
|
1
|
+
Metadata-Version: 2.4
|
2
|
+
Name: drap
|
3
|
+
Version: 0.0.2
|
4
|
+
Summary: Tool for analyzing droplet size and concentration using video and EDF images
|
5
|
+
Author-email: "Gabriel Braga Marques Teobaldo a, Oleg Prymak c, Natalie Wolff c, Matthias Epple c, Marco Aurélio Brizzotti Andrade b, Cássio Alves d and Cristiano Luis Pinto de Oliveira" <alves.casssio@gmail.com>
|
6
|
+
License: MIT
|
7
|
+
Project-URL: Homepage, https://test.pypi.org/project/DrAP/
|
8
|
+
Project-URL: Source, https://test.pypi.org/project/DrAP/
|
9
|
+
Keywords: saxs,x-ray,edf,opencv,pyqt5,droplet
|
10
|
+
Requires-Python: >=3.8
|
11
|
+
Description-Content-Type: text/markdown
|
12
|
+
License-File: LICENSE
|
13
|
+
Requires-Dist: opencv-python
|
14
|
+
Requires-Dist: numpy
|
15
|
+
Requires-Dist: matplotlib
|
16
|
+
Requires-Dist: fabio
|
17
|
+
Requires-Dist: pillow
|
18
|
+
Requires-Dist: reportlab
|
19
|
+
Requires-Dist: PyQt5
|
20
|
+
Dynamic: license-file
|
21
|
+
|
22
|
+
# Droplet Analyzer
|
23
|
+
|
24
|
+
This package allows the analysis of videos and images in EDF format to extract
|
25
|
+
physical parameters of droplets in acoustic levitation or other experimental techniques.
|
26
|
+
The graphical user interface provides:
|
27
|
+
|
28
|
+
- Region of interest cropping
|
29
|
+
- Morphological analysis
|
30
|
+
- Polynomial fitting of data
|
31
|
+
- PDF report generation
|
32
|
+
|
33
|
+
## How to use
|
34
|
+
|
35
|
+
Install:
|
drap-0.0.2/README.md
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
# Droplet Analyzer
|
2
|
+
|
3
|
+
This package allows the analysis of videos and images in EDF format to extract
|
4
|
+
physical parameters of droplets in acoustic levitation or other experimental techniques.
|
5
|
+
The graphical user interface provides:
|
6
|
+
|
7
|
+
- Region of interest cropping
|
8
|
+
- Morphological analysis
|
9
|
+
- Polynomial fitting of data
|
10
|
+
- PDF report generation
|
11
|
+
|
12
|
+
## How to use
|
13
|
+
|
14
|
+
Install:
|
@@ -0,0 +1,32 @@
|
|
1
|
+
[build-system]
|
2
|
+
requires = ["setuptools>=61.0", "wheel"]
|
3
|
+
build-backend = "setuptools.build_meta"
|
4
|
+
|
5
|
+
[project]
|
6
|
+
name = "drap"
|
7
|
+
version = "0.0.2"
|
8
|
+
description = "Tool for analyzing droplet size and concentration using video and EDF images"
|
9
|
+
readme = "README.md"
|
10
|
+
license = {text = "MIT"}
|
11
|
+
authors = [{ name = "Gabriel Braga Marques Teobaldo a, Oleg Prymak c, Natalie Wolff c, Matthias Epple c, Marco Aurélio Brizzotti Andrade b, Cássio Alves d and Cristiano Luis Pinto de Oliveira", email = "alves.casssio@gmail.com" }]
|
12
|
+
requires-python = ">=3.8"
|
13
|
+
|
14
|
+
dependencies = [
|
15
|
+
"opencv-python",
|
16
|
+
"numpy",
|
17
|
+
"matplotlib",
|
18
|
+
"fabio",
|
19
|
+
"pillow",
|
20
|
+
"reportlab",
|
21
|
+
"PyQt5"
|
22
|
+
]
|
23
|
+
|
24
|
+
keywords = ["saxs", "x-ray", "edf", "opencv", "pyqt5", "droplet"]
|
25
|
+
|
26
|
+
[project.scripts]
|
27
|
+
drap = "drap.main:main"
|
28
|
+
drap-gui = "drap.gui:main_gui"
|
29
|
+
|
30
|
+
[project.urls]
|
31
|
+
Homepage = "https://test.pypi.org/project/DrAP/"
|
32
|
+
Source = "https://test.pypi.org/project/DrAP/"
|
drap-0.0.2/setup.cfg
ADDED
@@ -0,0 +1,61 @@
|
|
1
|
+
from .conc_scat_video import conc_scat_video # e outros imports necessários
|
2
|
+
from .utils import get_info_video, get_video_file, get_dir_paths
|
3
|
+
|
4
|
+
import cv2
|
5
|
+
from fabio.edfimage import EdfImage
|
6
|
+
import tkinter as tk
|
7
|
+
from tkinter import filedialog
|
8
|
+
from pathlib import Path
|
9
|
+
import numpy
|
10
|
+
import matplotlib.pyplot as plt
|
11
|
+
import string
|
12
|
+
from PIL import Image
|
13
|
+
from reportlab.lib.pagesizes import A4, letter
|
14
|
+
from reportlab.platypus import SimpleDocTemplate, Table, TableStyle
|
15
|
+
from reportlab.pdfgen import canvas
|
16
|
+
from reportlab.lib import colors
|
17
|
+
import os
|
18
|
+
import copy
|
19
|
+
import time as timelib
|
20
|
+
from datetime import datetime
|
21
|
+
from datetime import timedelta
|
22
|
+
import numpy as np
|
23
|
+
import sys
|
24
|
+
from PyQt5.QtWidgets import QApplication, QMainWindow, QLabel, QVBoxLayout, QWidget, QPushButton, QFileDialog, QMessageBox, QLineEdit, QHBoxLayout, QGroupBox, QCheckBox
|
25
|
+
from PyQt5.QtGui import QPixmap, QPainter, QPen, QImage, QMouseEvent, QColor
|
26
|
+
from PyQt5.QtCore import Qt, QPoint, QRect, QFileInfo
|
27
|
+
import re
|
28
|
+
import argparse
|
29
|
+
import cv2
|
30
|
+
import matplotlib
|
31
|
+
|
32
|
+
import matplotlib.pyplot as plt
|
33
|
+
|
34
|
+
matplotlib.use('Agg')
|
35
|
+
|
36
|
+
|
37
|
+
|
38
|
+
def main_batch():
|
39
|
+
|
40
|
+
|
41
|
+
list_files = 'name_videos.dat';
|
42
|
+
|
43
|
+
set_file_1 = conc_scat_video(1, file_in = list_files);
|
44
|
+
|
45
|
+
set_file_1.read_video();
|
46
|
+
# print("Fimm ---")
|
47
|
+
# exit(0)
|
48
|
+
set_file_1.read_setfiles_edf(option = 1);
|
49
|
+
set_file_1.read_setfiles_edf(option = 0);
|
50
|
+
set_file_1.read_setfiles_edf();
|
51
|
+
# print("Fimm ---")
|
52
|
+
# exit(0)
|
53
|
+
|
54
|
+
set_file_2 = conc_scat_video(2, file_in = list_files);
|
55
|
+
set_file_2.read_video();
|
56
|
+
set_file_2.read_setfiles_edf(option = 0);
|
57
|
+
set_file_2.read_setfiles_edf(option = 1);
|
58
|
+
set_file_2.read_setfiles_edf();
|
59
|
+
|
60
|
+
concatene_files_scat_back(set_file_1, set_file_2);
|
61
|
+
|
@@ -0,0 +1,35 @@
|
|
1
|
+
Metadata-Version: 2.4
|
2
|
+
Name: drap
|
3
|
+
Version: 0.0.2
|
4
|
+
Summary: Tool for analyzing droplet size and concentration using video and EDF images
|
5
|
+
Author-email: "Gabriel Braga Marques Teobaldo a, Oleg Prymak c, Natalie Wolff c, Matthias Epple c, Marco Aurélio Brizzotti Andrade b, Cássio Alves d and Cristiano Luis Pinto de Oliveira" <alves.casssio@gmail.com>
|
6
|
+
License: MIT
|
7
|
+
Project-URL: Homepage, https://test.pypi.org/project/DrAP/
|
8
|
+
Project-URL: Source, https://test.pypi.org/project/DrAP/
|
9
|
+
Keywords: saxs,x-ray,edf,opencv,pyqt5,droplet
|
10
|
+
Requires-Python: >=3.8
|
11
|
+
Description-Content-Type: text/markdown
|
12
|
+
License-File: LICENSE
|
13
|
+
Requires-Dist: opencv-python
|
14
|
+
Requires-Dist: numpy
|
15
|
+
Requires-Dist: matplotlib
|
16
|
+
Requires-Dist: fabio
|
17
|
+
Requires-Dist: pillow
|
18
|
+
Requires-Dist: reportlab
|
19
|
+
Requires-Dist: PyQt5
|
20
|
+
Dynamic: license-file
|
21
|
+
|
22
|
+
# Droplet Analyzer
|
23
|
+
|
24
|
+
This package allows the analysis of videos and images in EDF format to extract
|
25
|
+
physical parameters of droplets in acoustic levitation or other experimental techniques.
|
26
|
+
The graphical user interface provides:
|
27
|
+
|
28
|
+
- Region of interest cropping
|
29
|
+
- Morphological analysis
|
30
|
+
- Polynomial fitting of data
|
31
|
+
- PDF report generation
|
32
|
+
|
33
|
+
## How to use
|
34
|
+
|
35
|
+
Install:
|
@@ -0,0 +1,14 @@
|
|
1
|
+
LICENSE
|
2
|
+
README.md
|
3
|
+
pyproject.toml
|
4
|
+
src/__init__.py
|
5
|
+
src/automation.py
|
6
|
+
src/gui.py
|
7
|
+
src/main.py
|
8
|
+
src/terminal_interface.py
|
9
|
+
src/drap.egg-info/PKG-INFO
|
10
|
+
src/drap.egg-info/SOURCES.txt
|
11
|
+
src/drap.egg-info/dependency_links.txt
|
12
|
+
src/drap.egg-info/entry_points.txt
|
13
|
+
src/drap.egg-info/requires.txt
|
14
|
+
src/drap.egg-info/top_level.txt
|
@@ -0,0 +1 @@
|
|
1
|
+
|
drap-0.0.2/src/gui.py
ADDED
@@ -0,0 +1,46 @@
|
|
1
|
+
from .conc_scat_video import conc_scat_video # e outros imports necessários
|
2
|
+
from .utils import get_info_video, get_video_file, get_dir_paths
|
3
|
+
|
4
|
+
import cv2
|
5
|
+
from fabio.edfimage import EdfImage
|
6
|
+
import tkinter as tk
|
7
|
+
from tkinter import filedialog
|
8
|
+
from pathlib import Path
|
9
|
+
import numpy
|
10
|
+
import matplotlib.pyplot as plt
|
11
|
+
import string
|
12
|
+
from PIL import Image
|
13
|
+
from reportlab.lib.pagesizes import A4, letter
|
14
|
+
from reportlab.platypus import SimpleDocTemplate, Table, TableStyle
|
15
|
+
from reportlab.pdfgen import canvas
|
16
|
+
from reportlab.lib import colors
|
17
|
+
import os
|
18
|
+
import copy
|
19
|
+
import time as timelib
|
20
|
+
from datetime import datetime
|
21
|
+
from datetime import timedelta
|
22
|
+
import numpy as np
|
23
|
+
import sys
|
24
|
+
from PyQt5.QtWidgets import QApplication, QMainWindow, QLabel, QVBoxLayout, QWidget, QPushButton, QFileDialog, QMessageBox, QLineEdit, QHBoxLayout, QGroupBox, QCheckBox
|
25
|
+
from PyQt5.QtGui import QPixmap, QPainter, QPen, QImage, QMouseEvent, QColor
|
26
|
+
from PyQt5.QtCore import Qt, QPoint, QRect, QFileInfo
|
27
|
+
import re
|
28
|
+
import argparse
|
29
|
+
import cv2
|
30
|
+
import matplotlib
|
31
|
+
|
32
|
+
import matplotlib.pyplot as plt
|
33
|
+
|
34
|
+
matplotlib.use('Agg')
|
35
|
+
|
36
|
+
|
37
|
+
from .image_cropper_full import ImageCropper # importa sua classe real
|
38
|
+
|
39
|
+
|
40
|
+
|
41
|
+
def main_gui():
|
42
|
+
app = QApplication(sys.argv)
|
43
|
+
cropper = ImageCropper()
|
44
|
+
sys.exit(app.exec_())
|
45
|
+
|
46
|
+
|
drap-0.0.2/src/main.py
ADDED
@@ -0,0 +1,71 @@
|
|
1
|
+
import cv2
|
2
|
+
from fabio.edfimage import EdfImage
|
3
|
+
import tkinter as tk
|
4
|
+
from tkinter import filedialog
|
5
|
+
from pathlib import Path
|
6
|
+
import numpy
|
7
|
+
import matplotlib.pyplot as plt
|
8
|
+
import string
|
9
|
+
from PIL import Image
|
10
|
+
from reportlab.lib.pagesizes import A4, letter
|
11
|
+
from reportlab.platypus import SimpleDocTemplate, Table, TableStyle
|
12
|
+
from reportlab.pdfgen import canvas
|
13
|
+
from reportlab.lib import colors
|
14
|
+
import os
|
15
|
+
import copy
|
16
|
+
import time as timelib
|
17
|
+
from datetime import datetime
|
18
|
+
from datetime import timedelta
|
19
|
+
import numpy as np
|
20
|
+
import sys
|
21
|
+
from PyQt5.QtWidgets import QApplication, QMainWindow, QLabel, QVBoxLayout, QWidget, QPushButton, QFileDialog, QMessageBox, QLineEdit, QHBoxLayout, QGroupBox, QCheckBox
|
22
|
+
from PyQt5.QtGui import QPixmap, QPainter, QPen, QImage, QMouseEvent, QColor
|
23
|
+
from PyQt5.QtCore import Qt, QPoint, QRect, QFileInfo
|
24
|
+
import re
|
25
|
+
import argparse
|
26
|
+
import cv2
|
27
|
+
import matplotlib
|
28
|
+
|
29
|
+
import matplotlib.pyplot as plt
|
30
|
+
|
31
|
+
matplotlib.use('Agg')
|
32
|
+
|
33
|
+
|
34
|
+
def main():
|
35
|
+
import argparse
|
36
|
+
parser = argparse.ArgumentParser()
|
37
|
+
parser.add_argument("-o", "--option", type=int, help="Execution mode: 1=GUI, 2=Terminal, 3=Batch")
|
38
|
+
args = parser.parse_args()
|
39
|
+
|
40
|
+
if args.option == 1:
|
41
|
+
from .gui import main_gui
|
42
|
+
main_gui()
|
43
|
+
elif args.option == 2:
|
44
|
+
from .terminal_interface import main_terminal
|
45
|
+
main_terminal()
|
46
|
+
elif args.option == 3:
|
47
|
+
from .automation import main_batch
|
48
|
+
main_batch()
|
49
|
+
else:
|
50
|
+
print("Use -o [1|2|3] to select a mode.")
|
51
|
+
|
52
|
+
|
53
|
+
|
54
|
+
|
55
|
+
|
56
|
+
|
57
|
+
|
58
|
+
|
59
|
+
|
60
|
+
|
61
|
+
|
62
|
+
|
63
|
+
|
64
|
+
|
65
|
+
|
66
|
+
|
67
|
+
|
68
|
+
|
69
|
+
|
70
|
+
|
71
|
+
|
@@ -0,0 +1,66 @@
|
|
1
|
+
from .conc_scat_video import conc_scat_video # e outros imports necessários
|
2
|
+
from .utils import get_info_video, get_video_file, get_dir_paths
|
3
|
+
|
4
|
+
import cv2
|
5
|
+
from fabio.edfimage import EdfImage
|
6
|
+
import tkinter as tk
|
7
|
+
from tkinter import filedialog
|
8
|
+
from pathlib import Path
|
9
|
+
import numpy
|
10
|
+
import matplotlib.pyplot as plt
|
11
|
+
import string
|
12
|
+
from PIL import Image
|
13
|
+
from reportlab.lib.pagesizes import A4, letter
|
14
|
+
from reportlab.platypus import SimpleDocTemplate, Table, TableStyle
|
15
|
+
from reportlab.pdfgen import canvas
|
16
|
+
from reportlab.lib import colors
|
17
|
+
import os
|
18
|
+
import copy
|
19
|
+
import time as timelib
|
20
|
+
from datetime import datetime
|
21
|
+
from datetime import timedelta
|
22
|
+
import numpy as np
|
23
|
+
import sys
|
24
|
+
from PyQt5.QtWidgets import QApplication, QMainWindow, QLabel, QVBoxLayout, QWidget, QPushButton, QFileDialog, QMessageBox, QLineEdit, QHBoxLayout, QGroupBox, QCheckBox
|
25
|
+
from PyQt5.QtGui import QPixmap, QPainter, QPen, QImage, QMouseEvent, QColor
|
26
|
+
from PyQt5.QtCore import Qt, QPoint, QRect, QFileInfo
|
27
|
+
import re
|
28
|
+
import argparse
|
29
|
+
import cv2
|
30
|
+
import matplotlib
|
31
|
+
|
32
|
+
import matplotlib.pyplot as plt
|
33
|
+
|
34
|
+
matplotlib.use('Agg')
|
35
|
+
|
36
|
+
|
37
|
+
def main_terminal():
|
38
|
+
|
39
|
+
function = choose_funtion();
|
40
|
+
|
41
|
+
if function == 1:
|
42
|
+
video_file = get_video_file();
|
43
|
+
print("Wait, This operation may take some time.")
|
44
|
+
infos = get_info_video();
|
45
|
+
set_file_1 = conc_scat_video(3, file_video = video_file, px_mm = infos[5] , step = infos[0], time_limit = infos[6], retangulo = [infos[1], infos[2], infos[3],infos[4]] );
|
46
|
+
set_file_1.read_video();
|
47
|
+
elif function == 2:
|
48
|
+
directory, root_file, _ = get_dir_paths(get_file_root = True);
|
49
|
+
set_file_1 = conc_scat_video(4,path = directory, root_name = root_file);
|
50
|
+
set_file_1.read_setfiles_edf(option = 1);
|
51
|
+
elif function == 3:
|
52
|
+
directory, root_file, file_path = get_dir_paths(get_file_root = True, get_file_path = True);
|
53
|
+
set_file_1 = conc_scat_video(5,path = directory, root_name = root_file, input_file = file_path);
|
54
|
+
set_file_1.read_setfiles_edf(option = 0);
|
55
|
+
elif function == 4:
|
56
|
+
print("\nNow TYPE information about SAMPLES.")
|
57
|
+
directory, root_file, file_path = get_dir_paths(get_file_path = True);
|
58
|
+
set_file_1 = conc_scat_video(5,path = directory, input_file = file_path);
|
59
|
+
set_file_1.read_setfiles_edf(option = 2);
|
60
|
+
|
61
|
+
print("\nNow TYPE information about BACKGROUND.")
|
62
|
+
directory, _, file_path = get_dir_paths(get_file_path = True);
|
63
|
+
set_file_2 = conc_scat_video(5,path = directory, input_file = file_path);
|
64
|
+
set_file_2.read_setfiles_edf(option = 2);
|
65
|
+
|
66
|
+
concatene_files_scat_back(set_file_1, set_file_2);
|