Skip to content

Commit

Permalink
enormous update from my 1 month project (CDD) (#51)
Browse files Browse the repository at this point in the history
* enormous update from my 1 month project (CDD)

* update requirements

* update pytest

* handle 2D image and update pytest

* update save/open/new project with .iag files

iag (image analysis graph) are json-like files and contains project settings.

* prepare for multiple graphs

* allow to open/save multiple project on same app

* update pytest

* fix pytest

* update process/thread handle and comment

* delete session folder

* fix compilation issue

* [#46] handle colored images

* Fixes test about click & foots

* Update text file test

* Let all codecov checks only be informational

* explain menu from dict

* Add thresholding with percentage

* [#52] Add thresholding with percentage

* [#52] Add thresholding with percentage

* dictionnary to dictionary

* Remove unecessary requirement

* empty filenames

Co-authored-by: Hboni <[email protected]>
  • Loading branch information
jeaunrg and Hboni authored Jul 3, 2021
1 parent 159320d commit efc869e
Show file tree
Hide file tree
Showing 58 changed files with 4,494 additions and 1,575 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# output folder
resources/data/out/*
resources/data/tmp/*

# Byte-compiled / optimized / DLL files
__pycache__/
Expand Down
3 changes: 3 additions & 0 deletions codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,6 @@ coverage:
project:
default:
informational: true
patch:
default:
informational: true
36 changes: 36 additions & 0 deletions config/default.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"window_size": [
1920,
1013
],
"window_position": [
15,
-9
],
"module_width": 250,
"space_between_modules": [
50,
50
],
"background_color": [
216,
255,
217
],
"arrow": {
"width": 2,
"arrowWidth": 6,
"arrowLen": 6,
"space": [
0,
10
],
"color": "QtGui.QColor(77, 120, 204)",
"borderWidth": 0,
"borderColor": "QtGui.QColor(77, 120, 204)"
},
"style": "Default",
"theme": "bright",
"filenames": [],
"current_tab": -1
}
24 changes: 0 additions & 24 deletions config/graph.json

This file was deleted.

94 changes: 56 additions & 38 deletions config/modules.json
Original file line number Diff line number Diff line change
@@ -1,42 +1,60 @@
{
"load image": {
"type": "primary",
"ui": "LoadImage.ui",
"function": "load_image"
"primary": {
"Load": {
"label": "importer",
"function": "call_load",
"color": [255, 198, 179, 255]
},
"delimiter_1": {},
"colorBackground": {
"label": "couleur du fond"
}
},
"threshold image": {
"type": "secondary",
"menu": "thresholding",
"ui": "ThresholdImage.ui",
"function": "update_threshold"
},
"operation between images": {
"type": "secondary",
"menu": "operation",
"ui": "Operation.ui",
"function": "operation_between_images"
},
"operation with single value": {
"type": "secondary",
"menu": "operation",
"ui": "SimpleOperation.ui",
"function": "operation_with_single_value"
},
"morpho basics": {
"type": "secondary",
"menu": "morpho",
"ui": "MorphoBasics.ui",
"function": "morpho_basics"
},
"save image": {
"type": "secondary",
"ui": "SaveImage.ui",
"function": "save_image"
},
"rename": {
"type": "secondary"
},
"delete": {
"type": "secondary"

"secondary": {
"seuillage": {
"ThresholdImage": {
"label": "standard",
"function": "call_apply_threshold",
"color": [255, 198, 179, 255]
}
},
"opération": {
"SimpleOperation": {
"label": "standard",
"function": "call_apply_simple_operation",
"color": [255, 198, 179, 255]
},
"Operation": {
"label": "inter-images",
"function": "call_apply_operation",
"nparents": -1,
"color": [255, 198, 179, 255]
}
},
"description": {
"GetInfo": {
"label": "min/max/mean",
"function": "call_get_img_infos",
"color": [255, 198, 179, 255]
}
},
"morphologie math.": {
"MorphoBasics": {
"label": "standard",
"function": "call_apply_basic_morpho",
"color": [255, 198, 179, 255]
}
},
"Save": {
"label": "enregistrer",
"function": "call_save",
"color": [255, 198, 179, 255]
},
"delimiter_1": {},

"rename": {"label": "renommer"},
"changeColor": {"label": "changer la couleur"},
"delete": {"label": "supprimer"}
}
}
7 changes: 5 additions & 2 deletions main.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
from src import app
from src.app import main
import multiprocessing


if __name__ == "__main__":
app.main()
multiprocessing.freeze_support()
main()
7 changes: 4 additions & 3 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
matplotlib==3.3.3
numpy==1.20.2
nibabel==3.2.1
scikit_image==0.18.0
numpy==1.20.2
PyQt5==5.15.3
pandas==1.1.5
psutil==5.7.2
cryptography==3.4.7
PyQt5==5.15.4
Empty file added resources/data/.gitignore
Empty file.
Binary file added resources/data/Lena.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/data/lean_crop.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/data/lena_colored.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/data/lena_gray.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 0 additions & 4 deletions resources/data/out/.gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +0,0 @@
# Ignore everything in this directory
*
# Except this file
!.gitignore
1 change: 1 addition & 0 deletions resources/data/simple_text.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Hello there!
Binary file removed resources/design/fail.png
Binary file not shown.
Binary file removed resources/design/loading.gif
Binary file not shown.
Binary file removed resources/design/valid.png
Binary file not shown.
Binary file added resources/icon/DropDownArrow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/icon/app.ico
Binary file not shown.
Binary file added resources/icon/pause.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/icon/play.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/icon/release.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/icon/save.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/icon/stop.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 9 additions & 0 deletions resources/qss/Default.qss
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
QProgressBar {
max-height: 2px;
border-color: transparent;
background-color: transparent;
}

QProgressBar::chunk {
background-color: qlineargradient(spread:pad, x1:0, x2:1, stop:0 transparent, stop:0.5 green, stop:1 transparent);
}
Loading

0 comments on commit efc869e

Please sign in to comment.