SwimBikeRun4342
Mechanical
- Mar 6, 2013
- 28
I am trying to write a very quick python script that imports amplitude data from a .txt file at a different location. I have zero experience with python and could really use some help. Below is the (very small) python code.
# -*- coding: mbcs -*-
from part import *
from material import *
from section import *
from assembly import *
from step import *
from interaction import *
from load import *
from mesh import *
from job import *
from sketch import *
from visualization import *
from connectorBehavior import *
from sys import path
path.append('D:\New Folder\Config2_Automated')
mdb.models['Model-1'].TabularAmplitude(name='Amp-1',input=TopLeg_TopJoint_FxQ2.txt, smooth=SOLVER_DEFAULT, timeSpan=STEP)
I get the following error:
NameError: name 'TopLeg_TopJoint_FxQ2' is not defined
So basically, I want to simply import the .txt file into my ABAQUS model, as an amplitude. Since the file is located elsewhere, I tried to write a path. However, my path must still not work because I get the error that my .txt file is not defined. Any suggestions? What does the error mean and how do I get ABAQUS/python to recognize the .txt file??
Thanks!
# -*- coding: mbcs -*-
from part import *
from material import *
from section import *
from assembly import *
from step import *
from interaction import *
from load import *
from mesh import *
from job import *
from sketch import *
from visualization import *
from connectorBehavior import *
from sys import path
path.append('D:\New Folder\Config2_Automated')
mdb.models['Model-1'].TabularAmplitude(name='Amp-1',input=TopLeg_TopJoint_FxQ2.txt, smooth=SOLVER_DEFAULT, timeSpan=STEP)
I get the following error:
NameError: name 'TopLeg_TopJoint_FxQ2' is not defined
So basically, I want to simply import the .txt file into my ABAQUS model, as an amplitude. Since the file is located elsewhere, I tried to write a path. However, my path must still not work because I get the error that my .txt file is not defined. Any suggestions? What does the error mean and how do I get ABAQUS/python to recognize the .txt file??
Thanks!