dlubal-software / rfem_python_client Goto Github PK
View Code? Open in Web Editor NEWPython client (or high-level functions) for RFEM 6 using Web Services, SOAP and WSDL
Home Page: https://dlubal-software.github.io/.github/
License: MIT License
Python client (or high-level functions) for RFEM 6 using Web Services, SOAP and WSDL
Home Page: https://dlubal-software.github.io/.github/
License: MIT License
Please change import of initModel module in the main example so that GUI is displayed and after that connection with RFEM6 is established.
At the moment there is the function Member(). With this function members can be defined by specifying start and end nodes. For example, you cannot define members that have the shape of an arc.
Another function is to be added, where members are defined by the line number.
Describe the bug
in member.py the method Member.Beam is defined as an instance method with self as first argument
def Beam(self,
but in test_member.py Member.Beam is used like a static/class method of the Member Class
Member.Beam(0, 1, 1, 2, MemberSectionDistributionType.SECTION_DISTRIBUTION_TYPE_UNIFORM, MemberRotationSpecificationType.COORDINATE_SYSTEM_ROTATION_VIA_ANGLE, [0.2618], 1, 1)
with 0 as an additional parameter for self and not as an instance method
Expected behavior
Member.Beam should be defined as a static method without self as first argument
@staticmethod
def Beam(no: int = 1,
As all the arguments to this method have default values, using kwargs is a great thing to produce readable code like this:
Member.Beam(
no=1,
start_node_no=1,
end_node_no=2,
start_section_no=1,
)
this raises an error because self is not defined.
btw:
rotation_parameters = [0],
is again an example for a mutable default argument
This is just an example for this design pattern that is used on many locations
Describe the bug
get_results_for_nodes_support_forces
returns different types for px, py, pz, mx, my, mz
To Reproduce
call for WebService directly:
get_results_for_nodes_support_forces
or for python:
result_list = ResultTables.NodesSupportForces(loading_type=loading_type, loading_no=loading_no, object_no=1)
# check types
for entry in result_list:
for key, value in entry.items():
print(key, type(value))
# write to json
result_dict = {}
for index, entry in enumerate(result_list):
result_dict[index] = entry
with open("C:\Dev\RFEM_Python_Client-main\RFEM_Python_Client-main\Examples\Cantilever\ResultTables\_Nodes_support_forces.json", "w") as file:
file.write(json.dumps(result_dict, indent=2))
Expected behavior
One type for: px, py, pz, mx, my, mz.
Looking at deformation ResultTables.NodesDeformation I would expected float type for all
Desktop (please complete the following information):
Hello Dlubal-Team
I'm looking to add a nodal support via python. Is it possible to define the stiffness with a diagram, as it can be done by "hand" (shown in the first image) ?
As documented in the manual i can add constant values with the "support" parameter. But I could not figure it out how to add it with a diagram.
Could you guide me how to do this properly
Best regards,
Pascal
Describe the bug
We want to create a result combination through the API / webservice that consists of other result combinations. Doing so through the GUI works fine.
When printing the manually created SUD object (result combination), the case object number is returned, but not the type (so it is not specified whether the item contains a LC or an RC).
To Reproduce
in my manually created result combination, the 2nd entry consists of case_object_item = 3. This could either be RC3 or LC3, which is not specified when printing the object.
(result_combination_items_row){
no = 2
description = None
row =
(result_combination_items){
case_object_item = 3
operator_type = "OPERATOR_OR"
left_parenthesis = False
right_parenthesis = False
case_object_factor = 1.0
case_object_load_type = "LOAD_TYPE_TRANSIENT"
}
},
I also tried setting a result_combination_item with an added case_object_type (or case_object) = "E_OBJECT_TYPE_RESULT_COMBINATION" but it does not work (suds.TypeNotFound: Type not found: 'case_object_type).
Expected behavior
I am hoping to have solution provided in the webservice calls to create result combinations from result combinations. More specifically, I want to specify the case object type in a result combination item. Something like:
(result_combination_items){
case_object_type = "E_OBJECT_TYPE_RESULT_COMBINATION"
case_object_item = 3
etc.
}
or
(result_combination_items){
case_object_type = “E_OBJECT_TYPE_LOAD_CASE”
case_object_item = 3
etc.
}
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
Additional context
I would like to see this issue solved because being able to nest Result combinations within Result combinations makes reading the results a lot more simple and straight forward. Thanks in advance!
Is your feature request related to a problem? Please describe.
It seems like get_all_object_numbers_by_type
is not supported yet.
I would like to get all object numbers it case when ResultTables data dump is needed for all object with specific Type
Describe the solution you'd like
Example patch I right now use:
import enum
from RFEM.initModel import Model
from RFEM.enums import ObjectTypes
def GetNumbers(object_numbers):
lstOfNumbers = []
if object_numbers:
for on in object_numbers[0]:
lstOfNumbers.append(on.no)
return lstOfNumbers
else:
return None
class ObjectNumbers():
@staticmethod
def GetAllObjectNumbersByType(
type_: enum = ObjectTypes.E_OBJECT_TYPE_NODE,
model = Model
):
object_numbers = model.clientModel.service.get_all_object_numbers_by_type(type_.name)
return GetNumbers(object_numbers)
Call:
print(ObjectNumbers.GetAllObjectNumbersByType(ObjectTypes.E_OBJECT_TYPE_NODE))
print(ObjectNumbers.GetAllObjectNumbersByType(ObjectTypes.E_OBJECT_TYPE_MEMBER))
print(ObjectNumbers.GetAllObjectNumbersByType(ObjectTypes.E_OBJECT_TYPE_SOLID_GAS))
Result:
[9, 1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 13, 14, 15, 16, 25, 26, 27, 28, 33, 34, 35, 36]
[9, 1, 2, 3, 4, 5, 6, 7, 8]
None
Create simple parametric example
The main aim is to present capability of Python High level functions and Web Services
Content of the example:
Originally posted by damianbobrowski September 30, 2022
Hello
Is there any programmatic way or documentation available to get know which Action Category from list of 258 elements:
https://github.com/Dlubal-Software/RFEM_Python_Client/blob/main/RFEM/enums.py#L1851
is true for given current_standard_for_combination_wizard
documented via doc string here:
https://github.com/Dlubal-Software/RFEM_Python_Client/blob/main/RFEM/LoadCasesAndCombinations/loadCasesAndCombinations.py#L21
For example for NATIONAL_ANNEX_AND_EDITION_EN_1990_CEN_2010_04 we have 18 Action Categories matched
Edit [03.10.2022]
This question is relevant also for DesignSituationType
https://github.com/Dlubal-Software/RFEM_Python_Client/blob/main/RFEM/enums.py#L1920
Describe the bug
Files *.js, *.css, *.png are not send with RFEM package, they exit on repository:
https://github.com/Dlubal-Software/RFEM_Python_Client/tree/main/RFEM/Reports.
They are used here:
https://github.com/Dlubal-Software/RFEM_Python_Client/blob/main/RFEM/Reports/html.py#L275
copy(os.path.join(dirname, 'htmlStyles.css'), TargetFolderPath)
copy(os.path.join(dirname, 'htmlScript.js'), TargetFolderPath)
copy(os.path.join(dirname, 'favicon32.png'), TargetFolderPath)
As result it is not possible to generate HTML report out of the box.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Used files are packed with package, not only exists on repository
Desktop (please complete the following information):
Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
When retrieving a ResultTables
(in my case MemberInternalForces
) with the object_no =0
(as discussed during the course in NL last week) the member numbers are stripped from the output. Which makes if difficult to work with the provided output.
It seems this is due to a (uncontrollable) setting in the ResultTables
class methods which all return ConvertResultsToListOfDct
with the includeBase
variable set to False, which in turn strips the no
of from the output.
Describe the solution you'd like
A clear and concise description of what you want to happen.
object_no
value to 0
to output all objects by default.includeBase
parameter in the ConvertResultsToListOfDct
function
if object_no == 0 and includeBase=False: includeBase = True
)Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Don't use the support functions and make the SOAP calls and ConvertResultsToListOfDct
call directly from application code:
_InnerForces = Model.clientModel.service.get_results_for_members_internal_forces(
CaseObjectType.E_OBJECT_TYPE_LOAD_CASE.name, 2, 0)
InnerForces = ConvertResultsToListOfDct(_InnerForces, True)
Additional context
Add any other context or screenshots about the feature request here.
How do I query the model, e.g. for existing nodes, members, internal forces and so on?
I am looking for loading RSECTIONs.
What are the plans about releasing to public methods implemented at RFEM.Tools.sectionDialogue
?
Model WebService definition for RFEM version 6.02.0030 seems to not expose used methods
> python 1.py
Connecting to server...
Traceback (most recent call last):
File "C:\Dev\1.py", line 21, in <module>
print(CreateSectionFromRsectionFile())
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\rfem-1.12.0-py3.9.egg\RFEM\Tools\sectionDialogue.py", line 44, in CreateSectionFromRsectionFile
model.clientModel.service.create_section_from_rsection_file(no, file_path)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\suds_py3-1.4.5.0-py3.9.egg\suds\client.py", line 316, in __getattr__
return getattr(port, name)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\suds_py3-1.4.5.0-py3.9.egg\suds\client.py", line 420, in __getattr__
return getattr(m, name)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\suds_py3-1.4.5.0-py3.9.egg\suds\client.py", line 511, in __getattr__
return self[name]
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\suds_py3-1.4.5.0-py3.9.egg\suds\client.py", line 524, in __getitem__
raise MethodNotFound(qn)
suds.MethodNotFound: Method not found: 'RfemModel.RfemModelPort.create_section_from_rsection_file'
Add option to initModel so that user is able to decide if he wants to delete results of project during initialization of connection.
Describe the bug
LoadCombination(...) Yields: "AttributeError: 'NoneType' object has no attribute 'factor'
in
...\Rfem\LoadCasesAndCombinations\loadCombinations.py
at mlvlp.row.factor = combination_items[i][0]
.
Can't get it to work, even with the default arguments, ie. "LoadCombination()"
To Reproduce
Expected behavior
A loadcombination with default parameters according to
no: int = 1,
analysis_type = AnalysisType.ANALYSIS_TYPE_STATIC,
design_situation: int = 1,
name: str = '',
static_analysis_settings: int = 1,
consider_imperfection: bool = False,
consider_initial_state: bool = False,
structure_modification: bool = False,
to_solve: bool = True,
combination_items = [[1.5, 1, 0, False]],
comment: str = '',
params: dict = None,
model = Model):
Seems to be an issue with the combination_items argument.
Describe the bug
ResultTables.CriticalLoadFactors() returns ' ' , even with a loadcase defined with the 'calculate critical load' parameter enabled.
Similar commands in the ResultTables module seem to work as expected, example ResultTables.MembersInternalForces()
Expected behavior
A list of critical load factors for the calculation conducted. The lists produced by ResultTables are usually hard to discern but valuable data can be extracted.
Similar results are found when trying a surface exclusive commands (for example ResultTables.SurfacesEquivalentStressesMises()) on a model using strictly members.
`
from RFEM.enums import *
from RFEM.initModel import *
from RFEM.BasicObjects.material import Material
from RFEM.BasicObjects.section import Section
from RFEM.BasicObjects.node import Node
from RFEM.BasicObjects.line import Line
from RFEM.BasicObjects.member import Member
from RFEM.TypesForNodes.nodalSupport import *
from RFEM.LoadCasesAndCombinations.staticAnalysisSettings import StaticAnalysisSettings
from RFEM.LoadCasesAndCombinations.stabilityAnalysisSettings import StabilityAnalysisSettings
from RFEM.LoadCasesAndCombinations.loadCase import LoadCase
from RFEM.LoadCasesAndCombinations.loadCombination import LoadCombination
from RFEM.Loads.memberLoad import *
from RFEM.Calculate.meshSettings import GetModelInfo
from RFEM.TypesForNodes.nodalSupport import setNodalSupportConditions
from RFEM.Results.resultTables import ResultTables
from RFEM.Reports.html import *
from RFEM.Reports.printoutReport import *
from RFEM.ImportExport.exports import *
from RFEM.TypesForMembers.memberHinge import *
import numpy as np
import pandas as pd
import re
Model(new_model=False, model_name = 'Referensmodell_struktur_python')
Model.clientModel.service.begin_modification()
#Geometrically Linear Static analysis
StaticAnalysisSettings.GeometricallyLinear(no=1,
name = 'Fully Linear')
#Linear Buckling Modes
StabilityAnalysisSettings.EigenvalueMethod(1,'Eigenvector Linear' , 10, True, False, None, None,
StabilityAnalysisSettingsEigenvalueMethod.EIGENVALUE_METHOD_LANCZOS,
StabilityAnalysisSettingsMatrixType.MATRIX_TYPE_STANDARD)
#Create load case and combinations.
LoadCase.StaticAnalysis(no=1,
name='Lineload + Prestress',
to_solve = True,
analysis_settings_no = 1,
self_weight = [False],
params = {'calculate_critical_load': True, 'stability_analysis_settings': 1})
MemberLoad.Force(no=1,
load_case_no=1,
members_no = '28,61',
load_distribution = MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM,
load_direction = MemberLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_TRUE,
load_parameter =[36e3 + 4.8e3]) #30 kN utbredd last.
MemberLoad.InitialPrestress(no=2,
load_case_no= 1,
members_no = '32,31,68,64,65',
load_direction= MemberLoadDirection.LOAD_DIRECTION_LOCAL_X,
magnitude = 600e3) #600 kN förspänning.
NodalSupport(no = 6, support = NodalSupportType.FREE,
params = {'name': "Tryckbom_param", 'nodes': "58 59 113 114",'spring_x': 0,'spring_y': 11e6,'spring_z': 0, 'coordinate_system' : 1})
Calculate_all()
clf = ResultTables.CriticalLoadFactors()
print(clf)
`
I would like to have an example where I can see how to model beams which has spline, arc or other shape than just straight line
Can't quite wrap my head around how the first argument of
Model.clientModel.service.calculate_specific(ns0:calculate_specific_loadings loadings, xs:boolean skip_warnings)
is structured.
With
test = Model.clientModel.factory.create('ns0:calculate_specific_loadings')
test.loading = [1,3]
Model.clientModel.service.calculate_specific(test.loading,True)
I get "Server raised fault: 'Given data do not have expected structure.'"
Since the code I'm working with is for editing an already created client model, I tried
lc1 = Model.clientModel.service.get_load_case(1)
test = Model.clientModel.factory.create('ns0:calculate_specific_loadings')
test.loading = [lc1]
Model.clientModel.service.calculate_specific(test.loading,True)
Which returns error: Server raised fault: 'loadings: '
But it's more or less shooting in the dark, need some help with this one.
There is a function,
CalculateSelectedCases()
But that tries to create
'ns0:array_of_calculate_specific_objects_elements'
which gives error: Type not found: 'ns0:array_of_calculate_specific_objects_elements'
This type doesn't seem to exist anywhere in the documentation, atleast that i can find.
We should have some good examples for existing RF-COM users how to easily port their string handling to the new PYTHON setup.
i.e. How to code '1, 3-5, 78-119, 129, 131' into a set of integers in PYTHON. I say that we have already the insertspaces function, but i think to enable a faster adaptopn we need it to be in the same ways in in RF-COM 5.xx or RFEM 6 tables.
Describe the bug
To set the area density variable (as seen on the printscreen) to a thickness via the webservice with the SI unit N/m^2 does not seem to convert it to kg/m^2 (see GUI on printscreen).
We provided the value 13441.67 [N/m^2] and expect the value 1344.167 [kg/m^2] in the GUI (after the model is saved).
To Reproduce
The following call is made:
Thickness.StiffnessMatrix(
no = self._thickness_count,
name = thickness_name,
material_no = material_num,
stiffness_matrix= stiffness_matrix,
consideration_of_self_weight = [ThicknessStiffnessMatrixSelfWeightDefinitionType.SELF_WEIGHT_DEFINITION_TYPE_DEFINED_VIA_FICTITIOUS_THICKNESS_AND_AREA_DENSITY, fictitious_thickness, area_density]
)
Expected behavior
We provided the value 13441.67 [N/m^2] and expect the value 1344.167 [kg/m^2] in the GUI (after the model is saved).
Screenshots
Desktop (please complete the following information):
I am trying to create a code that models simple beams based on user defined properties and loading on a separate .xlsx file.
I would like to be able to create a new model and change:
i) Units from metric to imperial.
ii) Both the 'Load Case...' and 'Load Wizards' from EN 1990 to ASCE 7 (for wood).
So far, I have been able to enter the loads but having issues with the action category classification.
I attached my code, any help on this would be really appreciated! Thanks in advance.
from RFEM.baseSettings import BaseSettings
from RFEM.enums import ActionCategoryType, MemberLoadDirection, MemberLoadDistribution
from RFEM.initModel import Model, Calculate_all
from RFEM.initModel import clearAttributes, ConvertToDlString
from RFEM.BasicObjects.material import Material
from RFEM.BasicObjects.section import Section
from RFEM.BasicObjects.node import Node
from RFEM.BasicObjects.member import Member
from RFEM.TypesForNodes.nodalSupport import NodalSupport
from RFEM.TypesForNodes.nodalSupport import setNodalSupportConditions
from RFEM.dataTypes import inf
from RFEM.LoadCasesAndCombinations.loadCasesAndCombinations import LoadCasesAndCombinations
from RFEM.LoadCasesAndCombinations.staticAnalysisSettings import StaticAnalysisSettings
from RFEM.LoadCasesAndCombinations.loadCase import LoadCase
from RFEM.Loads.memberLoad import MemberLoad
from RFEM.Calculate.meshSettings import GetModelInfo
from userinput import userinput2
info = userinput2()
l = info[0] / 3.28
U_material = info[1]
U_section = info[2]
U_loadtype = info[3]
U_deadload = info[4]
U_liveload = info[5]
U_trib = info[6]
if name == 'main':
# Creates a new model on RFEM -- This is where I would change the units and standards?
Model(True, "BPA_Beam_yv01", False, False)
LoadCasesAndCombinations({"current_standard_for_combination_wizard": 6238,
"activate_combination_wizard_and_classification": True,
"activate_combination_wizard": True,
"result_combinations_active": False,
"result_combinations_parentheses_active": False,
"result_combinations_consider_sub_results": False,
"combination_name_according_to_action_category": True}, Model)
# Unlocks model to allow for edits
Model.clientModel.service.begin_modification()
# Enter materials
Material(1, U_material)
# Enter beam cross-sections
Section(1, U_section)
# Enter beam nodes
Node(1, 0.0, 0.0, 0.0)
Node(2, l, 0.0, 0.0)
# Create members
Member(1, 1, 2, 0.0, 1, 1)
# Assigns supports
NodalSupport(1, '1', [inf, inf, inf, inf, 0.0, inf]) # Moment release about GLOBAL Y
NodalSupport(2, '2', [0.0, inf, inf, inf, 0.0, inf]) # Moment release about GLOBAL Y & Displacement release about GLOBAL X
# Create load cases
LoadCase.StaticAnalysis(1, 'DL', True, 1, action_category=ActionCategoryType.ACTION_CATEGORY_DEAD_LOAD_D)
LoadCase.StaticAnalysis(2, 'LL', True, 1, action_category=ActionCategoryType.ACTION_CATEGORY_LIVE_LOAD_L)
# Assign member loads based on USER INPUT Need to convert to kip/ft
if U_loadtype == 'Uniform':
DEAD = (U_deadload * U_trib) * 14.5939
LIVE = (U_liveload * U_trib) * 14.5939
MemberLoad.Force(1, 1, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_PROJECTED,[DEAD])
MemberLoad.Force(2, 2, '1', MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W_PROJECTED, [LIVE])
# End of model edits
Model.clientModel.service.finish_modification()
'
Describe the bug
Method not found: 'RfemModel.RfemModelPort.get_all_object_numbers_by_type'
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Code should start the calculations in RFEM
Desktop:
Is your feature request related to a problem? Please describe.
I am trying to run multiple models in parallel. Everything seems to run until Calculation starts.
Model which start calculation letter crash.
I am wondering is it connected to Calculation or User Interface (UI) in general.
Working with library I see when dialog is open then it blocks even one model from start.
During calculations UI "start working" so it can be UI blocking issue.
Describe the solution you'd like
Possibility to run multiple models in parallel. Non blocking solution.
Is there ready non UI version/"server version" of software?
Traceback
python .\models\2.py
Connecting to server...
[DEBUG] Program start took: 0:00:00.000001
[DEBUG] Creating model (model_main_parameters){
model_id = "{482332d8-3045-446d-a2db-1f191b666ab7}"
model_name = "2"
model_description = None
model_comment = None
model_path = "2"
project_id = None
project_name = None
project_description = None
project_folder = None
} took: 0:00:03.942335
[DEBUG] [{482332d8-3045-446d-a2db-1f191b666ab7}] Begin modification took: 0:00:00.005806
[DEBUG] [{482332d8-3045-446d-a2db-1f191b666ab7}] Materials took: 0:00:00.098687
[DEBUG] [{482332d8-3045-446d-a2db-1f191b666ab7}] Sections took: 0:00:00.244222
[DEBUG] [{482332d8-3045-446d-a2db-1f191b666ab7}] Nodes took: 0:00:00.244056
[DEBUG] [{482332d8-3045-446d-a2db-1f191b666ab7}] NodelSupports took: 0:00:00.109208
[DEBUG] [{482332d8-3045-446d-a2db-1f191b666ab7}] Member Hinges took: 0:00:00.906680
[DEBUG] [{482332d8-3045-446d-a2db-1f191b666ab7}] Members took: 0:00:00.578673
[DEBUG] [{482332d8-3045-446d-a2db-1f191b666ab7}] StaticAnalysisSettings took: 0:00:00.093260
[DEBUG] [{482332d8-3045-446d-a2db-1f191b666ab7}] LoadCasesAndCombinationWizard took: 0:00:00.504737
Traceback (most recent call last):
File "C:\Dev\dlubal\models\2.py", line 149, in <module>
DesignSituation(2, DesignSituationType.DESIGN_SITUATION_TYPE_STR_PERMANENT_AND_TRANSIENT_6_10, True, "Stress")
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\rfem-1.12.0-py3.9.egg\RFEM\LoadCasesAndCombinations\designSituation.py", line 55, in __init__
model.clientModel.service.set_design_situation(clientObject)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\suds_py3-1.4.5.0-py3.9.egg\suds\client.py", line 559, in __call__
return client.invoke(args, kwargs)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\suds_py3-1.4.5.0-py3.9.egg\suds\client.py", line 618, in invoke
result = self.send(soapenv)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\suds_py3-1.4.5.0-py3.9.egg\suds\client.py", line 658, in send
result = self.succeeded(binding, reply.message)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\suds_py3-1.4.5.0-py3.9.egg\suds\client.py", line 696, in succeeded
reply, result = binding.get_reply(self.method, reply)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\suds_py3-1.4.5.0-py3.9.egg\suds\bindings\binding.py", line 152, in get_reply
self.detect_fault(soapbody)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python39\lib\site-packages\suds_py3-1.4.5.0-py3.9.egg\suds\bindings\binding.py", line 183, in detect_fault
raise WebFault(p, fault)
suds.WebFault: b"Server raised fault: 'It is not possible to execute the operation. Another operation is probably running in the application or a dialog is open.'"
Used model
To reproduce just run two scripts in parallel after differentiation
MODEL_NAME = "1"
from RFEM.BasicObjects.material import Material
from RFEM.BasicObjects.member import Member
from RFEM.BasicObjects.node import Node
from RFEM.BasicObjects.section import Section
from RFEM.dataTypes import inf
from RFEM.enums import (
ActionCategoryType,
AnalysisType,
DesignSituationType,
LoadDirectionType,
MemberHingeDiagramType,
MemberHingeNonlinearity,
MemberLoadDirection,
MemberLoadDistribution,
)
from RFEM.ImportExport.exports import ExportResultTablesToCSV
from RFEM.initModel import Calculate_all, closeModel, Model
from RFEM.LoadCasesAndCombinations.designSituation import DesignSituation
from RFEM.LoadCasesAndCombinations.loadCase import LoadCase
from RFEM.LoadCasesAndCombinations.loadCasesAndCombinations import (
LoadCasesAndCombinations,
)
from RFEM.LoadCasesAndCombinations.loadCombination import LoadCombination
from RFEM.LoadCasesAndCombinations.staticAnalysisSettings import StaticAnalysisSettings
from RFEM.Loads.memberLoad import MemberLoad
from RFEM.Loads.nodalLoad import NodalLoad
from RFEM.TypesForMembers.memberHinge import MemberHinge
from RFEM.TypesForNodes.nodalSupport import NodalSupport
# from RFEM.Calculate.meshSettings import GetModelInfo
from timeit import default_timer as timer
from datetime import timedelta
def log(what, start):
end = timer()
time = timedelta(seconds=end-start)
print(f"[DEBUG] {what} took:", time)
return timer()
if __name__ == "__main__":
# input("Press eny key to start...")
_start = log("Program start", timer())
MODEL_NAME = "1"
model = Model(True, MODEL_NAME)
params = model.clientModel.service.get_model_main_parameters()
model_id = model.clientModel.service.get_model_main_parameters().model_id
_start = log(f"Creating model {params}", _start)
# input("Model Created, press eny key to continue...")
Model.clientModel.service.begin_modification()
_start = log(f"[{model_id}] Begin modification", _start)
# input("Model Created, press eny key to continue...")
# breakpoint()
# **STRUCTURE**------------------------------------------------
# -------------------------------------------------------------
# MaterialCustomDefinitions
material_custom_definition_1 = {}
material_custom_definition_16 = {}
# Materials
"""
Material definition matching pattern:
name = "<Material>"
Material(2, "S235H (EN 10210-1)")
Material(3, "S220 1.4541 (cold rolled strip)")
"""
Material(1, "S235", params=None)
_start = log(f"[{model_id}] Materials", _start)
# -------------------------------------------------------------
# SectionCustomDefinitions
section_custom_definition_2 = {}
section_custom_definition_3 = {'A': 3.25, 'comment': 'Test', 'is_active': False}
# Sections
"""
Section definition matching pattern"
name = "<Section> | <Standard?> | <Manufacturer?>":
Section(2, "IPE 400") # default, probably first matching
Section(3, "IPE 400 | -- | British Steel")
Section(4, "IPE 400 | EN 10365:2017 | ArcelorMittal (2018)")
Section(5, "IPE 400 | DIN 1025-5:1994-03 | Ferona")
"""
Section(1, "IPE 100 | EN 10365:2017 | ArcelorMittal (2018)", params=None)
Section(4, "IPE 100 | DIN 1025-5:1994-03 | Ferona", params=None)
_start = log(f"[{model_id}] Sections", _start)
# -------------------------------------------------------------
# Nodes
Node(12, 0.0, 0.0, 0.0)
Node(13, 2.0, 0.0, 0.0)
Node(14, 2.0, 0.0, -2.0)
Node(15, 0.0, 0.0, -2.0)
_start = log(f"[{model_id}] Nodes", _start)
# -------------------------------------------------------------
# NodalSupports
NodalSupport(1, "12 13 ", [inf, inf, inf, inf, inf, inf])
_start = log(f"[{model_id}] NodelSupports", _start)
# -------------------------------------------------------------
# MemberHingeNonlinearity
member_hinge_diagram_nonlinearity_1 = [MemberHingeNonlinearity.NONLINEARITY_TYPE_DIAGRAM, [MemberHingeDiagramType.DIAGRAM_ENDING_TYPE_CONTINUOUS, MemberHingeDiagramType.DIAGRAM_ENDING_TYPE_CONTINUOUS, [[0.001, 5280, None], [0.0015, 9240, None], [0.002, 12770, None], [0.0025, 15420, None], [0.003, 17450, None], [0.004, 20480, None], [0.005, 22706, None]]]]
member_hinge_diagram_nonlinearity_2 = [MemberHingeNonlinearity.NONLINEARITY_TYPE_DIAGRAM, [MemberHingeDiagramType.DIAGRAM_ENDING_TYPE_STOP, MemberHingeDiagramType.DIAGRAM_ENDING_TYPE_STOP, [[0.001, 5280, None], [0.0015, 9240, None], [0.002, 12770, None], [0.0025, 15420, None], [0.003, 17450, None], [0.004, 20480, None], [0.005, 22706, None]]]]
member_hinge_diagram_nonlinearity_3 = [MemberHingeNonlinearity.NONLINEARITY_TYPE_DIAGRAM, [MemberHingeDiagramType.DIAGRAM_ENDING_TYPE_FAILURE, MemberHingeDiagramType.DIAGRAM_ENDING_TYPE_FAILURE, [[0.001, 5280, None], [0.0015, 9240, None], [0.002, 12770, None], [0.0025, 15420, None], [0.003, 17450, None], [0.004, 20480, None], [0.005, 22706, None]]]]
member_hinge_diagram_nonlinearity_4 = [MemberHingeNonlinearity.NONLINEARITY_TYPE_DIAGRAM, [MemberHingeDiagramType.DIAGRAM_ENDING_TYPE_YIELDING, MemberHingeDiagramType.DIAGRAM_ENDING_TYPE_YIELDING, [[0.001, 5280, None], [0.0015, 9240, None], [0.002, 12770, None], [0.0025, 15420, None], [0.003, 17450, None], [0.004, 20480, None], [0.005, 22706, None]]]]
# MemberHinges
MemberHinge(1, "Local", "", 0, 0, 0, 0, 0, 0, member_hinge_diagram_nonlinearity_1, member_hinge_diagram_nonlinearity_2, member_hinge_diagram_nonlinearity_3, member_hinge_diagram_nonlinearity_4, member_hinge_diagram_nonlinearity_4, member_hinge_diagram_nonlinearity_2)
MemberHinge(2, "Local", "", 500, 500, 300, inf, 0, inf, [MemberHingeNonlinearity.NONLINEARITY_TYPE_NONE], [MemberHingeNonlinearity.NONLINEARITY_TYPE_NONE], [MemberHingeNonlinearity.NONLINEARITY_TYPE_NONE], [MemberHingeNonlinearity.NONLINEARITY_TYPE_NONE], [MemberHingeNonlinearity.NONLINEARITY_TYPE_NONE], [MemberHingeNonlinearity.NONLINEARITY_TYPE_NONE])
_start = log(f"[{model_id}] Member Hinges", _start)
# -------------------------------------------------------------
# Members
Member(11, 12, 13, 1.570796, 1, 1, None, None)
Member(12, 13, 14, 1.570796, 1, 1, None, None)
Member(13, 12, 15, 1.570796, 1, 1, None, None)
Member(14, 15, 14, 1.570796, 1, 1, None, None)
_start = log(f"[{model_id}] Members", _start)
# **LOAD_CASES_AND_COMBINATIONS**------------------------------
# -------------------------------------------------------------
# This is created by default when user opens new model from GUI
StaticAnalysisSettings.GeometricallyLinear(1, "Linear")
# StaticAnalysisSettings.SecondOrderPDelta(2, "SecondOrder")
# StaticAnalysisSettings.LargeDeformation(3, "LargeDeformation")
_start = log(f"[{model_id}] StaticAnalysisSettings", _start)
# -------------------------------------------------------------
# LoadCasesAndCombinationWizard
load_cases_and_combinations_settings = {
"current_standard_for_combination_wizard": 6207,
"activate_combination_wizard_and_classification": True,
"activate_combination_wizard": False,
"result_combinations_active": False,
"result_combinations_parentheses_active": False,
"result_combinations_consider_sub_results": False,
"combination_name_according_to_action_category": False
}
LoadCasesAndCombinations(load_cases_and_combinations_settings)
_start = log(f"[{model_id}] LoadCasesAndCombinationWizard", _start)
# -------------------------------------------------------------
# DesignSituations
DesignSituation(2, DesignSituationType.DESIGN_SITUATION_TYPE_STR_PERMANENT_AND_TRANSIENT_6_10, True, "Stress")
DesignSituation(3, DesignSituationType.DESIGN_SITUATION_TYPE_SLS_CHARACTERISTIC, True, "Deflection")
_start = log(f"[{model_id}] DesignSituations", _start)
# -------------------------------------------------------------
# LoadCases
LoadCase(1, "Self Weight", [True, 0.0, 0.0, 1.0], params={"action_category": ActionCategoryType.ACTION_CATEGORY_PERMANENT_G.name})
LoadCase(2, "FinishMaterials", [False], params={"action_category": ActionCategoryType.ACTION_CATEGORY_PERMANENT_G.name})
LoadCase(3, "Wind X", [False], params={"action_category": ActionCategoryType.ACTION_CATEGORY_WIND_QW.name})
LoadCase(4, "Wind Y", [False], params={"action_category": ActionCategoryType.ACTION_CATEGORY_WIND_QW.name})
_start = log(f"[{model_id}] LoadCases", _start)
# -------------------------------------------------------------
# LoadCombination
LoadCombination(1, AnalysisType.ANALYSIS_TYPE_STATIC, 2, combination_items=[[1.35, 1, 0, False], [1.35, 2, 0, False], [1.5, 3, 0, False]])
LoadCombination(2, AnalysisType.ANALYSIS_TYPE_STATIC, 2, combination_items=[[1.35, 1, 0, False], [1.35, 2, 0, False], [1.5, 4, 0, False]])
LoadCombination(3, AnalysisType.ANALYSIS_TYPE_STATIC, 2, combination_items=[[1.35, 1, 0, False], [1.35, 2, 0, False]])
LoadCombination(4, AnalysisType.ANALYSIS_TYPE_STATIC, 3, combination_items=[[1, 1, 0, False], [1, 2, 0, False], [1, 3, 0, False]])
LoadCombination(5, AnalysisType.ANALYSIS_TYPE_STATIC, 3, combination_items=[[1, 1, 0, False], [1, 2, 0, False], [1, 4, 0, False]])
_start = log(f"[{model_id}] LoadCombinations", _start)
# **LOADS**----------------------------------------------------
# -------------------------------------------------------------
# NodalLoads
NodalLoad.Force(1, 2, "14 15 ", LoadDirectionType.LOAD_DIRECTION_LOCAL_Z, 1000.0)
NodalLoad.Moment(2, 2, "14 ", LoadDirectionType.LOAD_DIRECTION_LOCAL_Z, 5000.0)
_start = log(f"[{model_id}] NodalLoads", _start)
# -------------------------------------------------------------
# MemberLoads
MemberLoad.Force(1, 3, "11 12 13 14 ", MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_GLOBAL_X_OR_USER_DEFINED_U_TRUE, [-1000.0])
MemberLoad.Force(2, 4, "11 12 13 14 ", MemberLoadDistribution.LOAD_DISTRIBUTION_UNIFORM, MemberLoadDirection.LOAD_DIRECTION_GLOBAL_Y_OR_USER_DEFINED_V_TRUE, [1000.0])
_start = log(f"[{model_id}] MemberLoads", _start)
# -------------------------------------------------------------
Model.clientModel.service.finish_modification()
_start = log(f"[{model_id}] FinishingModification", _start)
print("Start Calculation")
Calculate_all()
_start = log(f"[{model_id}] Calculation", _start)
ExportResultTablesToCSV("C:\\Dev\\dlubal\\results\\csv")
_start = log(f"[{model_id}] ExportToCSV", _start)
closeModel(MODEL_NAME)
_start = log(f"[{model_id}] ClosingModel", _start)
Describe the bug
Exporting an RFEM model of a CLT Thickness with 3 layers using the script generator yields an object like:
"thickness_layers_reference_table": [
{
"no": 1,
"row": {
"layer_no": 1,
"layer_type": "E_LAYER_TYPE_LAYER",
"thickness_type": 0,
"material": 1,
"thickness": 0.04,
"angle": 0.0,
"integration_points": 9,
"connection_with_other_topological_elements": False,
"specific_weight": 4200.0,
"weight": 168.0,
},
},
...
where thickness_type is 0
.
Trying to run that back against the server yields an errors with "Ungültiger Objekttyp" for the thickness_type
field. Changing it to "thickness_type": "1"
solved the problem. I.e. using 1 indexing and string instead of number (may not need the string, but the 0 didn't work.
Not sure what the thickness_type
references and if it is something I have misconfigured when trying to run the script against the server.
I cannot find anything in the exporter script that would define a thickness_type
to be referenced so maybe this should be exported as "1" in the first place?
Expected behavior
Roundtrip should be possible
Will add the RFEM model soon
I was happy to see that the problems with the CalculateSelectedCases (#233) are solved, however when i pulled the latest version of the library (1.16.0) I get the following error when rerunning my simple test script:
Exception has occurred: WebFault
b"Server raised fault: 'value: items: row: amplitude_function_type: Enumeration item '' not found.'"
File "F:\code\RFEM_Test\RFEM_Python_Client\RFEM\LoadCasesAndCombinations\loadCombination.py", line 101, in __init__
model.clientModel.service.set_load_combination(clientObject)
File "F:\code\RFEM_Test\test.py", line 128, in CreateLoadCases
LoadCombination(no=1,
File "F:\code\RFEM_Test\test.py", line 204, in <module>
CreateLoadCases()
suds.WebFault: b"Server raised fault: 'value: items: row: amplitude_function_type: Enumeration item '' not found.'"
with the previous version 1.15.0 the code to create the load combination worked fine.
Code to create load cases and load combination
LoadCase.StaticAnalysis(no=1,
name="Self-Weight",
to_solve=False,
analysis_settings_no=1,
action_category=ActionCategoryType.ACTION_CATEGORY_PERMANENT_G,
self_weight=[True,0,0,1])
LoadCase.StaticAnalysis(no=2,
name="Hook-Load",
to_solve=False,
analysis_settings_no=1,
action_category=ActionCategoryType.ACTION_CATEGORY_PERMANENT_G,
self_weight=[False])
NodalLoad.Force(no=1,
load_case_no=2,
nodes_no="3",
load_direction=LoadDirectionType.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W,
magnitude=500*1000)
LoadCombination(no=1,
analysis_type=AnalysisType.ANALYSIS_TYPE_STATIC,
name='CO1',
static_analysis_settings=1,
to_solve=True,
combination_items=[
[1.35, 1, 0, False],
[1.50, 2, 0, False]
])
Describe the bug
The assignments of line hinges does not work.
class LineHinge():
# Slab Wall Connection definition
slabWallConnection = {'slab_wall_connection': True,
'slab_wall_with_slab_edge_block': True,
'slab_wall_connection_offset': 0.15,
'slab_edge_block_width':0.1}
def __init__(self,
no: int = 1,
assigned_to: str = '3/5; 2/5',
translational_release: list = [800, inf, inf],
rotational_release_phi: int = inf,
comment: str = '',
params: dict = None,
model = Model):
"""
assigned_to doesn't work. Can't figure why.
Assignment in surfaces also doesn't work (surface.has_line_hinges = True).
Args:
no (int): Line Hinge Tag
assigned_to (str): Assigned to
translational_release (list): Translation Release List
rotational_release_phi (int): Rotational Release phi
comment (str, optional): Comments
params (dict, optional): Any WS Parameter relevant to the object and its value in form of a dictionary
model (RFEM Class, optional): Model to be edited
"""
# Client model | Line Hinge
clientObject = model.clientModel.factory.create('ns0:line_hinge')
# Clears object atributes | Sets all atributes to None
clearAttributes(clientObject)
# Line Hinge No.
clientObject.no = no
# Assigned to surface and its line (format 1/3)
clientObject.assigned_to = assigned_to
# Translatioonal and totational release
clientObject.translational_release_u_x = translational_release[0]
clientObject.translational_release_u_y = translational_release[1]
clientObject.translational_release_u_z = translational_release[2]
clientObject.rotational_release_phi_x = rotational_release_phi
# Slab connection
clientObject.slab_wall_connection = False
# Comment
clientObject.comment = comment
# Adding optional parameters via dictionary
if params:
for key in params:
clientObject[key] = params[key]
# Delete None attributes for improved performance
deleteEmptyAttributes(clientObject)
# Add Line Hinge to client model
model.clientModel.service.set_line_hinge(clientObject)
Don't reset model when connection is initialized so that user is able to modify model with his script.
current situation
Model stores clientModel as a class attribute so you it is not possible to work with more than one file
preferred solution
use a instance variable instead
self.clientModel
Add option to open project from path before client for model is created
Add option to create new project with specified name
Add option to select project from the list of opened projects in RFEM
Is your feature request related to a problem? Please describe.
Not a big deal: Just Code Spell Checker for VSCode reports problem.
Describe the solution you'd like
clearAtributes() --> clearAttributes()
atributes --> attributes
Describe the bug
setting multiple line loads leads to ->
Error: Line No. x is loaded, however, it does not belong to any surface.
To Reproduce
l = 10
f = 10
Model(True, "Demo1") # crete new model called Demo1
Model.clientModel.service.begin_modification()
Material(1, "S235")
Section(1, "IPE 200")
Node(1, 0.0, 0.0, 0.0)
Node(2, l, 0.0, 0.0)
Member(1, 1, 2, 0.0, 1, 1)
NodalSupport(1, "1", NodalSupportType.FIXED)
StaticAnalysisSettings.GeometricallyLinear(0, 1, "Linear")
StaticAnalysisSettings.SecondOrderPDelta(0, 2, "SecondOrder")
StaticAnalysisSettings.LargeDeformation(0, 3, "LargeDeformation")
line = str(dict(Model.clientModel.service.get_member(1))["line"]) # get line no. member 1
for i in range(1, 5):
LoadCase(i, "LC_{}".format(i), [False])
# NodalLoad(
# 1, i, "2", LoadDirectionType.LOAD_DIRECTION_GLOBAL_Z_OR_USER_DEFINED_W, i * 1000
# )
LineLoad(i, i, line, LoadDirectionType.LOAD_DIRECTION_LOCAL_Z, i * 1000)
Model.clientModel.service.finish_modification()
Describe the bug
When getting results from the model after calculation via the ResultTable class, an error occurs in the GetResultTableParameters()
function.
The object apears to be of the correct type when <suds.sudsobject.array_of_.....>
gets passed as the variable in the results
argument of the function.
The params 'no', 'description', 'row' are found. The error states that i.row.__keylist__
does not have the attribute keylist.
The error message:
AttributeError Traceback (most recent call last)
Cell In[19], line 1
----> 1 print(ConvertResultsToListOfDct(test_model.operator.model.clientModel.service.get_results_for_members_internal_forces(CaseObjectType.E_OBJECT_TYPE_RESULT_COMBINATION.name, 1, 0)))
File d:\Users\LEED\AppData\Local\pypoetry\Cache\virtualenvs\traffic-bridge-tool-ToYKuhA6-py3.10\lib\site-packages\RFEM\Results\resultTables.py:39, in ConvertResultsToListOfDct(results, includeBase)
36 if not results:
37 return ''
---> 39 params = GetResultTableParameters(results)
40 lstOfDct = []
42 for r in results[0]:
File d:\Users\LEED\AppData\Local\pypoetry\Cache\virtualenvs\traffic-bridge-tool-ToYKuhA6-py3.10\lib\site-packages\RFEM\Results\resultTables.py:22, in GetResultTableParameters(results)
20 params['base'] = list(set(params['base'] + i.__keylist__))
21 if 'row' in i.__keylist__:
---> 22 params['row'] = list(set(params['row'] + i.row.__keylist__))
23 else:
24 params['errors'] = "Result table doesn't have attribute 'row'."
AttributeError: 'Text' object has no attribute '__keylist__'
The error message appears on all types of getting results that I have tried:
ResultTables.SurfacesDesignInternalForces()
ResultTables.SurfacesPrincipalInternalForces()
ResultTables.MembersInternalForces()
ResultTables.NodesSupportForces()
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Results from the calculated model.
Screenshots
(array_of_surfaces_design_internal_forces){
surfaces_design_internal_forces[] =
(surfaces_design_internal_forces_row){
no = 1
description = "1"
row =
(surfaces_design_internal_forces){
grid_point =
(variant){
type = 2
value = "1"
}
grid_point_coordinate_x =
(variant){
type = 0
value = "0"
}
grid_point_coordinate_y =
(variant){
type = 0
value = "0"
}
grid_point_coordinate_z =
(variant){
type = 0
value = "0"
}
layer = 1
design_internal_force_label =
(variant){
type = 3
value = "max"
}
moment_mx_d_plus =
(variant){
type = 0
value = "325505.3125"
}
moment_my_d_plus =
(variant){
type = 0
value = "385527.125"
}
moment_mc_d_plus =
(variant){
type = 0
value = "-129206.1953125"
}
moment_mx_d_minus =
(variant){
type = 0
value = "2143023.25"
}
moment_my_d_minus =
(variant){
type = 0
value = "122564.828125"
}
moment_mc_d_minus =
(variant){
type = 0
value = "-44777.85546875"
}
axial_force_nx_d =
(variant){
type = 0
value = "683481.875"
}
axial_force_ny_d =
(variant){
type = 0
value = "865573.375"
}
axial_force_nc_d =
(variant){
type = 0
value = "-138398.859375"
}
specification = None
}
},
Desktop (please complete the following information):
Additional context
Add any other context about the problem here.
I'm not much of a coder, my apologies if I am simply making a mistake, however, it seems as though the LoadCombination function isn't functioning properly. I've run the test_loadCombination function as well as the loadcombination function in my own project, in both instances have I received the same error message: "Server raised fault: 'value: items: row: amplitude_function_type: Enumeration item '' not found. ' "
The amplitude_function_type is something that doesn't show up in the definition of the function. I've tried to solve this by addig it as a parameter without success.
Of course there still exists the possibility that I've missed something. Nevertheless I suspect this is an issue which isn't caused by my own coding inadequacies. Below I pasted a screen shot of the error which arised after running the test_loadingCombination() function.
My apologies if I'm not going through the proper channels, as you might have gathered I'm rather new to this.
The new update of loadCase.py always raises the error of 'WARNING: Entry at index 0 of Self-Weight parameter to be of type bool', when the self-weight is deactivated and set as [False].
Describe the bug
When running and creating a steel hall using the ws example script in PR#207, the wrong internal forces for columns are being exported and shown as results, This is because of the use of GetMaxValue( ) function.
To Reproduce
Steps to reproduce the behavior:
Execute SteelDesignExcel.py. Look at exported internal forces in Excel.
Expected behavior
Max compression force in column should be an entry with (-).
Getting error in branch : heet-memberLocalSectionReduction
after importing and calling SteelMemberLocalSectionReduction in example(Demo2), It raises WebFault: b"Server raised fault: 'Enumeration item '' not found.'"
If you want to create Mass type Member Load, script runs with no errors, but doesn't assign the load in RFEM6.
Changes and test file can be found in branch https://github.com/Dlubal-Software/RFEM_Python_Client/tree/dogukaratas-MemberLoad
If you start the main.py and click on "Run". An error is displayed.
PS C:\Users\faulstichf\git\RfemPythonWsClient> python .\main.py
Connecting to server...
Resetting model...
Geometry...
Web service reported a SOAP processing fault using an unexpected HTTP status code 200. Reporting as an internal server error.
<suds.sax.document.Document object at 0x000001FCA6A91220>
Exception in Tkinter callback
Traceback (most recent call last):
File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.8_3.8.2800.0_x64__qbz5n2kfra8p0\lib\tkinter\__init__.py", line 1892, in __call__
return self.func(*args)
File "C:\Users\faulstichf\git\RfemPythonWsClient\RFEM\window.py", line 89, in start
mainFunc(float(e1.get()),float(e2.get()),float(e3.get()),int(e5.get()),float(e4.get()))
File ".\main.py", line 42, in main
Section(4, "Cable 14.00", 2)
File "C:\Users\faulstichf\git\RfemPythonWsClient\RFEM\BasicObjects\section.py", line 34, in __init__
clientModel.service.set_section(clientObject)
File "C:\Users\faulstichf\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\suds\client.py", line 521, in __call__
return client.invoke(args, kwargs)
File "C:\Users\faulstichf\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\suds\client.py", line 581, in invoke
result = self.send(soapenv)
File "C:\Users\faulstichf\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\suds\client.py", line 620, in send
return self.process_reply(reply=reply.message,
File "C:\Users\faulstichf\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\suds\client.py", line 670, in process_reply
raise WebFault(fault, replyroot)
suds.WebFault: Server raised fault: 'Objekt: Querschnitt Nr. 4
Attribut: Querschnittsflächen - Axial
Fehler: Bitte geben Sie einen positiven Wert ein.'
PS C:\Users\faulstichf\git\RfemPythonWsClient>
Desktop:
I have several questions regarding using RFEM_Python package
First question is how to define a non-linear hinge, where the non-linearity is a diagram?
The second one is how to define a non-linear support, where the non-linearity is friction PZ?
The third one is: Is there any function to set axial offset from adjoining member?
The last one is what function can be used to generate load combinations?
Describe the bug
Hi,
I am trying to create result combinations with the RFEM 6 API through Python. I cannot specify which load cases, factors and operators to take into account when creating a result combination through the API. Looking at the documentation available, it seems that this class is incomplete and needs to be developed.
Is there any way through Python to specify result combinations including load cases, factors and operators? If not, when can I expect the ResultCombination class to be updated?
Expected behavior
Expect to be able to have the features to define a ResultCombination as in th GUI:
Desktop (please complete the following information):
Hello,
It would be really helpful to manipulate element and nodal points, specially when it comes to shell elements.
For instance, with this feature I could code things like:
This feature looks promising anyway 👍, although I miss a bit of documentation! Keep up with the good work!
Is your feature request related to a problem? Please describe.
The RFEM Python client depends on suds_requests, which also depends on 'use_2to3' from setuptools for it's installation. This was removed from setuptools in 58 - https://setuptools.pypa.io/en/latest/history.html#v58-0-0
github/suds_requests#12
Describe the solution you'd like
In the short term, downgrading setuptools and installing is sufficient, but a cleaner long-term solution would be preferred. The desired solution would ideally work with the latest versions of setup-tools, and work "out of the box" without any tinkering with environments. I understand this might be tricky however, many of these packages are out of Dlubal's control..
Hello,
it will be really helpful to have an example of taking results for mesh points / raster points using Python for specific load combinations.
Main question would be if new API provides faster method (in terms of computational time) to get these results, because for some reason taking results for already calculated model via RFEM 5 API can take few hours, which makes hard to use it via API and via Grasshopper.
Best regards ;)
The initiModel code has been modified recently.
With the previous commands the model can be initialized as follows (example):
Model(True, "SEM")
Model.clientModel.service.begin_modification("new")
But now I get AttributeError: Text object has no attribute name
so my question is how to initialize the model?
Originally posted by DannieCW July 4, 2023
Dear developers,
I am using the RFem API to create rectangular loads on a surface using the center, side and rotation option:
My load_location input is like this:
angle = 30
side = 0.4
load_location = [coordinate[0], coordinate[1], side, side, angle]
In the load generated in the RFEM_gui, the location coordinates and sides are presented correctly, but no rotation is taken from the input (see picture below). Would you be able to help me identify how did this happen?
Thank you.
Best regards,
Dannie
Rotation of free rectangular load is not assigning properly in RFEM. Value of rotation angle is passing to wrong attribute.
Is your feature request related to a problem? Please describe.
As far as we are aware there is no access to the tools within RFEM to manipulate the geometry of the model (for instance move / rotate commands). We are planning to work on a rather large model (which we can't share due to a signed NDA) which we need to rotate multiple times. The number of nodes currently involved is ~1500 which with the current setup are to be relocated one by one using a single SOAP request for each node. Currently a single rotation of all these nodes takes approximately 10-15 seconds.
Describe the solution you'd like
Either the option to dump the whole set of new coordinates in one request (i.e. in a single batch) or have access to the manipulation tools in RFEM. Alternatively asynchronous SOAP requests might be an option as well depending on the capabilities of the SOAP server and the suds library (Zeep could be an alternative SOAP library which does support asyncio).
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Add any other context or screenshots about the feature request here.
Required enumeration elements are missing at the moment for Line function.
Class Line has failed tests.
Problem:
When using the member rotation parameter, I noticed it needs to be input as radians for it to work. Should we change the required input type to degrees as that's what most User's will think of as an input?
Solution:
Include a simple rotation_angle * math.pi/180 in our member Python HLF to do the conversion.
Additional notes:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.