Skip to content

Commit

Permalink
デフォルトの max_workers の値をCPUの最大スレッド数に設定
Browse files Browse the repository at this point in the history
  • Loading branch information
KeiTa4446 committed Aug 6, 2024
1 parent 9214c67 commit 71465ca
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions dem_to_csmap.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import multiprocessing
import os

from PyQt5.QtCore import Qt
Expand Down Expand Up @@ -27,6 +28,9 @@ def __init__(self):
self.ui.mQgsFileWidget_output.setFilter("*.tif")
self.ui.mQgsFileWidget_output.setStorageMode(QgsFileWidget.StorageMode.SaveFile)

# デフォルトの max_workers の値をCPUの最大スレッド数に設定
self.ui.spinBoxMaxWorkers.setValue(multiprocessing.cpu_count())

# ボタンのクリックイベント
self.ui.pushButton_run.clicked.connect(self.convert_dem_to_csmap)
self.ui.pushButton_cancel.clicked.connect(self.close)
Expand Down

0 comments on commit 71465ca

Please sign in to comment.