I am trying to extract the equivalent stresses using DPF operators, scoped to a nodal named selection. This is a static structural simulation, for the record. For some reason, the extracted fields don't contain any data whatsoever. It lists out the mat and time ids for each node, in the field. But no stress values in the data attribute. Any possible reasons?
def post_started(sender, analysis):# Do not edit this line
define_dpf_workflow(analysis)
# Uncomment this function to enable retrieving results from the table/chart
# def table_retrieve_result(value):# Do not edit this line
# import mech_dpf
# import Ans.DataProcessing as dpf
# wf = dpf.Workflow(this.WorkflowId)
# wf.Connect('contour_selector', value)
# this.Evaluate()
def define_dpf_workflow(analysis):
import mech_dpf
import Ans.DataProcessing as dpf
mech_dpf.setExtAPI(ExtAPI)
s_eqv_op = dpf.operators.result.stress_eqv_as_mechanical()
s_eqv_op.inputs.requested_location.Connect('Nodal')
datasource = dpf.DataSources(analysis.ResultFileName)
my_model = dpf.Model(datasource)
s_eqv_op.inputs.datasources.Connect(datasource)
ns_scope = dpf.MeshScopingFactory.NamedSelectionScoping("BOLT_SHANK_UPPER_1",my_model)
s_eqv_op.inputs.mesh_scoping.Connect(ns_scope)
time_freq = my_model.TimeFreqSupport
nsets =time_freq.NumberSets
time_scope = dpf.TimeFreqScopingFactory.ScopingBySet(nsets)
s_eqv_op.inputs.time_scoping.Connect(time_scope)
dpf_workflow = dpf.Workflow()
dpf_workflow.Add(s_eqv_op)
dpf_workflow.SetOutputContour(s_eqv_op)
dpf_workflow.Record("wf_id",TRUE)
dpf_workflow.Record("wf_id",True)
this.WorkflowId = dpf_workflow.GetRecordedId()