Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing gui import error and adding some minor convenience #143

Merged
merged 4 commits into from
Jan 7, 2025
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ femmt/examples/femm
femmt/examples/mesh
femmt/custom_examples
gui/femmt
gui/GUI_working_directory
.idea/
femmt/__pycache__/
gpgit/
Expand Down
8 changes: 5 additions & 3 deletions gui/femmt_gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
import materialdatabase as mdb
import matplotlib.pyplot as plt

from gui.onelab_path_popup import OnelabPathDialog
from onelab_path_popup import OnelabPathDialog

from femmt.examples.inductor_optimization import AutomatedDesign
from femmt.examples.inductor_optimization import load_fem_simulation_results, filter_after_fem
Expand Down Expand Up @@ -3047,8 +3047,6 @@ def md_setup_geometry(self):
returns: femmt MagneticComponent

"""
# geo = fmt.MagneticComponent(component_type=fmt.ComponentType.Inductor, is_gui=True)
# self.check_onelab_config(geo)

if self.md_simulation_type_comboBox.currentText() == self.translation_dict['inductor']:
self.md_simulation_QLabel.setText('simulation starts...')
Expand All @@ -3064,7 +3062,9 @@ def md_setup_geometry(self):

geo = fmt.MagneticComponent(component_type=fmt.ComponentType.Inductor,
working_directory=self.md_working_directory_lineEdit.text(),
is_gui=True,
verbosity=fmt.Verbosity.ToConsole)
self.check_onelab_config(geo)

core_dimensions = fmt.dtos.SingleCoreDimensions(core_inner_diameter=comma_str_to_point_float(self.md_core_width_lineEdit.text()),
window_w=comma_str_to_point_float(self.md_window_width_lineEdit.text()),
Expand Down Expand Up @@ -3246,7 +3246,9 @@ def md_setup_geometry(self):
# 1. chose simulation type
geo = fmt.MagneticComponent(component_type=fmt.ComponentType.Transformer,
working_directory=self.md_working_directory_lineEdit.text(),
is_gui=True,
verbosity=fmt.Verbosity.ToConsole)
self.check_onelab_config(geo)

# -----------------------------------------------
# Core
Expand Down
4 changes: 2 additions & 2 deletions gui/femmt_gui.ui
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
</size>
</property>
<property name="currentIndex">
<number>3</number>
<number>0</number>
</property>
<widget class="QWidget" name="md_QWidget">
<attribute name="title">
Expand Down Expand Up @@ -2852,7 +2852,7 @@
</size>
</property>
<property name="currentIndex">
<number>3</number>
<number>0</number>
</property>
<widget class="QWidget" name="md_QWidget_3">
<attribute name="title">
Expand Down
Loading