Skip to content

Commit

Permalink
8.1.4
Browse files Browse the repository at this point in the history
  • Loading branch information
semiautomaticgit committed Nov 21, 2023
1 parent 30a59d4 commit 7cbac32
Show file tree
Hide file tree
Showing 7 changed files with 16,600 additions and 16,571 deletions.
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@ dclean:
find $(HOME)/.local/share/QGIS/QGIS3/profiles/default/python/plugins/$(PLUGINNAME) -iname "*.pyc" -delete
find $(HOME)/.local/share/QGIS/QGIS3/profiles/default/python/plugins/$(PLUGINNAME) -iname "__pycache__" -delete
find $(HOME)/.local/share/QGIS/QGIS3/profiles/default/python/plugins/$(PLUGINNAME) -iname "*.directory" -delete
find $(HOME)/.local/share/QGIS/QGIS3/profiles/default/python/plugins/$(PLUGINNAME) -iname "*.zip" -delete
find $(HOME)/.local/share/QGIS/QGIS3/profiles/default/python/plugins/$(PLUGINNAME) -iname "remotior_sensus" -exec rm -rv {} +
find $(HOME)/.local/share/QGIS/QGIS3/profiles/default/python/plugins/$(PLUGINNAME) -iname ".svn" -prune -exec rm -Rf {} \;

# The derase deletes deployed plugin
Expand Down
2 changes: 1 addition & 1 deletion __init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def description():


def version():
return 'Version 8.1.3 - Infinity'
return 'Version 8.1.4 - Infinity'


def icon():
Expand Down
30 changes: 30 additions & 0 deletions core/ui_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
# If not, see <https://www.gnu.org/licenses/>.


import os
import sys
import ssl
import smtplib

Expand All @@ -32,6 +34,11 @@
QHBoxLayout, QVBoxLayout, QToolButton, QApplication
)

# sound for Windows
try:
import winsound
except Exception as error:
str(error)

cfg = __import__(str(__name__).split('.')[0] + '.core.config', fromlist=[''])

Expand Down Expand Up @@ -261,6 +268,7 @@ def remove_progress_bar(self, smtp=None):
subject=self.translate('Semi-Automatic Classification Plugin'),
message=self.translate('%s: process finished' % smtp)
)
self.finish_sound()

# translate
@staticmethod
Expand Down Expand Up @@ -301,3 +309,25 @@ def send_smtp_message(subject: str = None, message: str = None):
server.quit()
except Exception as err:
str(err)

# finish sound
@staticmethod
def finish_sound():
if cfg.qgis_registry[cfg.reg_sound] == 2:
try:
beeps(800, 0.2)
beeps(600, 0.3)
beeps(700, 0.5)
except Exception as err:
str(err)


# beep sound
def beeps(frequency: int, duration: float):
if sys.platform.startswith('win'):
winsound.Beep(frequency, int(duration * 1000))
elif sys.platform.startswith('linux'):
os.system(
'play --no-show-progress --null --channels 1 synth %s sine %s'
% (str(duration), str(frequency))
)
6 changes: 0 additions & 6 deletions core/util_qgis.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,6 @@
QgsCoordinateReferenceSystem
)

# sound for Windows
try:
import winsound
except Exception as error:
str(error)

cfg = __import__(str(__name__).split('.')[0] + '.core.config', fromlist=[''])


Expand Down
4 changes: 2 additions & 2 deletions docs/repository.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?xml version = '1.0' encoding = 'UTF-8'?>
<plugins>
<pyqgis_plugin name="Semi-Automatic Classification Plugin - master" version="8.1.3" plugin_id="284">
<pyqgis_plugin name="Semi-Automatic Classification Plugin - master" version="8.1.4" plugin_id="284">
<description><![CDATA[The Semi-Automatic Classification Plugin (SCP) allows for the supervised classification of remote sensing images, providing tools for the download, the preprocessing and postprocessing of images.]]></description>
<about><![CDATA[Developed by Luca Congedo, the Semi-Automatic Classification Plugin (SCP) allows for the supervised classification of remote sensing images, providing tools for the download, the preprocessing and postprocessing of images. Search and download is available for Landsat, Sentinel-2 images. Several algorithms are available for the land cover classification. This plugin requires the installation of Remotior Sensus, GDAL, OGR, Numpy, SciPy, and Matplotlib. For more information please visit https://fromgistors.blogspot.com .]]></about>
<version>8.1.3</version>
<version>8.1.4</version>
<qgis_minimum_version>3.0.0</qgis_minimum_version>
<qgis_maximum_version>3.99.0</qgis_maximum_version>
<homepage><![CDATA[https://fromgistors.blogspot.com/p/semi-automatic-classification-plugin.html]]></homepage>
Expand Down
5 changes: 4 additions & 1 deletion metadata.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name=Semi-Automatic Classification Plugin
qgisMinimumVersion=3.00
description=The Semi-Automatic Classification Plugin (SCP) allows for the supervised classification of remote sensing images, providing tools for the download, the preprocessing and postprocessing of images.
version=8.1.3
version=8.1.4
about=Developed by Luca Congedo, the Semi-Automatic Classification Plugin (SCP) allows for the supervised classification of remote sensing images, providing tools for the download, the preprocessing and postprocessing of images. Search and download is available for Landsat, Sentinel-2 images. Several algorithms are available for the land cover classification. This plugin requires the installation of Remotior Sensus, GDAL, OGR, Numpy, SciPy, and Matplotlib. For more information please visit https://fromgistors.blogspot.com .

author=Luca Congedo
Expand All @@ -13,6 +13,9 @@ icon=semiautomaticclassificationplugin.png

changelog=

8.1.4
-fixed finish sound

8.1.3
-fixed classification tool

Expand Down
Loading

0 comments on commit 7cbac32

Please sign in to comment.