similar structure for building blocks

This commit is contained in:
Martin Diehl 2019-05-30 10:45:17 +02:00
parent 510b55df50
commit e974bb9c43
4 changed files with 7 additions and 4 deletions

View File

@ -89,8 +89,8 @@ for x in range(options.grid[0]):
geom=damask.Geom(microstructure,options.size,
homogenization=options.homogenization,
comments=[scriptID + ' ' + ' '.join(sys.argv[1:])])
damask.util.croak(geom)
if name is None:
sys.stdout.write(str(geom.show()))
else:

View File

@ -134,7 +134,8 @@ for i in range(3,np.max(microstructure)):
config_header.append('[Point{}]'.format(i-2))
config_header.append('(gauss)\tphi1 {:.2f}\tPhi {:.2f}\tphi2 0'.format(Alpha[i],Beta[i]))
header = [scriptID + ' ' + ' '.join(sys.argv[1:])] + config_header
header = [scriptID + ' ' + ' '.join(sys.argv[1:])]\
+ config_header
geom = damask.Geom(microstructure.reshape(grid),
size,-size/2,
homogenization=options.homogenization,comments=header)

0
processing/pre/geom_fromTable.py Normal file → Executable file
View File

View File

@ -194,16 +194,18 @@ parser.set_defaults(pos = 'pos',
normalized = True,
config = True,
)
(options,filenames) = parser.parse_args()
# --- loop over input files -------------------------------------------------------------------------
if filenames == []: filenames = [None]
for name in filenames:
table = damask.ASCIItable(name = name, readonly = True)
damask.util.report(scriptName,name)
table = damask.ASCIItable(name = name, readonly = True)
# --- read header ----------------------------------------------------------------------------
table.head_read()