Hi all. I keep getting this error with the latest version of sfepy when I run the following lines. Could you guys please help.
strain = pb.evaluate('ev_cauchy_strain.{dim}.Omega(u)'.format(dim=dims), mode='el_avg')
The above line works fine.
stress = pb.evaluate('ev_cauchy_stress.3.Omega(m.D, u)', copy_materials=False, mode='el_avg')
but the stress line always shows the error below. m is defined before in the problem with 'D' value.
File "C:\Python27\lib\site-packages\sfepy\discrete\problem.py", line 1264, in evaluate sfepy: allowed argument shapes for term "ev_cauchy_stress.3.Omega(m.D, u)": sfepy: [{'material': 'S, S', 'parameter': 'D'}] mode=mode, dw_mode=dw_mode, term_mode=term_mode) File "C:\Python27\lib\site-packages\sfepy\discrete\evaluate.py", line 280, in eval_equations term_mode=term_mode, asm_obj=asm_obj) File "C:\Python27\lib\site-packages\sfepy\discrete\equations.py", line 621, in evaluate term_mode=term_mode) File "C:\Python27\lib\site-packages\sfepy\discrete\equations.py", line 817, in evaluate ret_status=True) File "C:\Python27\lib\site-packages\sfepy\terms\terms.py", line 1337, in evaluate self.check_shapes(*args) File "C:\Python27\lib\site-packages\sfepy\terms\terms.py", line 1215, in check_shapes % term_str) ValueError: wrong arguments shapes for "ev_cauchy_stress.3.Omega(m.D, u)" term! (see above)
Hi!
On 01/09/2017 01:27 PM, samyak jain wrote:
Hi all. I keep getting this error with the latest version of sfepy when I run the following lines. Could you guys please help.
strain = pb.evaluate('ev_cauchy_strain.{dim}.Omega(u)'.format(dim=dims), mode='el_avg')
Note that the number after the term name has nothing to do with some dimension (assuming from your naming) - it is the numerical quadrature order.
The above line works fine.
stress = pb.evaluate('ev_cauchy_stress.3.Omega(m.D, u)', copy_materials=False, mode='el_avg')
but the stress line always shows the error below. m is defined before in the problem with 'D' value.
The D shape has to be (6, 6) in 3D or (3, 3) in 2D - can you check that?
r.
File "C:\Python27\lib\site-packages\sfepy\discrete\problem.py", line 1264, in evaluate sfepy: allowed argument shapes for term "ev_cauchy_stress.3.Omega(m.D, u)": sfepy: [{'material': 'S, S', 'parameter': 'D'}] mode=mode, dw_mode=dw_mode, term_mode=term_mode) File "C:\Python27\lib\site-packages\sfepy\discrete\evaluate.py", line 280, in eval_equations term_mode=term_mode, asm_obj=asm_obj) File "C:\Python27\lib\site-packages\sfepy\discrete\equations.py", line 621, in evaluate term_mode=term_mode) File "C:\Python27\lib\site-packages\sfepy\discrete\equations.py", line 817, in evaluate ret_status=True) File "C:\Python27\lib\site-packages\sfepy\terms\terms.py", line 1337, in evaluate self.check_shapes(*args) File "C:\Python27\lib\site-packages\sfepy\terms\terms.py", line 1215, in check_shapes % term_str) ValueError: wrong arguments shapes for "ev_cauchy_stress.3.Omega(m.D, u)" term! (see above)
Hi Robert,
Thanks for your reply. I have checked and it is (3,3). I am calculating D from stiffness_from_youngpoisson.
Thanks Samyak
On Monday, 9 January 2017 13:24:11 UTC, Robert Cimrman wrote:
Hi!
On 01/09/2017 01:27 PM, samyak jain wrote:
Hi all. I keep getting this error with the latest version of sfepy when
I
run the following lines. Could you guys please help.
strain = pb.evaluate('ev_cauchy_strain.{dim}.Omega(u)'.format(dim=dims),
mode='el_avg')
Note that the number after the term name has nothing to do with some dimension (assuming from your naming) - it is the numerical quadrature order.
The above line works fine.
stress = pb.evaluate('ev_cauchy_stress.3.Omega(m.D, u)',
copy_materials=False, mode='el_avg')
but the stress line always shows the error below. m is defined before in
the problem with 'D' value.
The D shape has to be (6, 6) in 3D or (3, 3) in 2D - can you check that?
r.
File "C:\Python27\lib\site-packages\sfepy\discrete\problem.py", line 1264, in evaluate sfepy: allowed argument shapes for term "ev_cauchy_stress.3.Omega(m.D,
u)":
sfepy: [{'material': 'S, S', 'parameter': 'D'}] mode=mode, dw_mode=dw_mode, term_mode=term_mode) File "C:\Python27\lib\site-packages\sfepy\discrete\evaluate.py", line 280, in eval_equations term_mode=term_mode, asm_obj=asm_obj) File "C:\Python27\lib\site-packages\sfepy\discrete\equations.py", line 621, in evaluate term_mode=term_mode) File "C:\Python27\lib\site-packages\sfepy\discrete\equations.py", line 817, in evaluate ret_status=True) File "C:\Python27\lib\site-packages\sfepy\terms\terms.py", line 1337,
in
evaluate self.check_shapes(*args) File "C:\Python27\lib\site-packages\sfepy\terms\terms.py", line 1215,
in
check_shapes % term_str) ValueError: wrong arguments shapes for "ev_cauchy_stress.3.Omega(m.D,
u)"
term! (see above)
Hi Robert,
I did check it again and my mistake was that stiffness_from_youngpoisson with first parameter as 2 and hence (3,3). I have changed it now and it is fine and works perfectly fine. Thanks a lot.
Samyak
On Monday, 9 January 2017 13:47:10 UTC, samyak jain wrote:
Hi Robert,
Thanks for your reply. I have checked and it is (3,3). I am calculating D from stiffness_from_youngpoisson.
Thanks Samyak
On Monday, 9 January 2017 13:24:11 UTC, Robert Cimrman wrote:
Hi!
On 01/09/2017 01:27 PM, samyak jain wrote:
Hi all. I keep getting this error with the latest version of sfepy when
I
run the following lines. Could you guys please help.
strain =
pb.evaluate('ev_cauchy_strain.{dim}.Omega(u)'.format(dim=dims), mode='el_avg')
Note that the number after the term name has nothing to do with some dimension (assuming from your naming) - it is the numerical quadrature order.
The above line works fine.
stress = pb.evaluate('ev_cauchy_stress.3.Omega(m.D, u)',
copy_materials=False, mode='el_avg')
but the stress line always shows the error below. m is defined before
in the problem with 'D' value.
The D shape has to be (6, 6) in 3D or (3, 3) in 2D - can you check that?
r.
File "C:\Python27\lib\site-packages\sfepy\discrete\problem.py", line 1264, in evaluate sfepy: allowed argument shapes for term "ev_cauchy_stress.3.Omega(m.D,
u)":
sfepy: [{'material': 'S, S', 'parameter': 'D'}] mode=mode, dw_mode=dw_mode, term_mode=term_mode) File "C:\Python27\lib\site-packages\sfepy\discrete\evaluate.py", line 280, in eval_equations term_mode=term_mode, asm_obj=asm_obj) File "C:\Python27\lib\site-packages\sfepy\discrete\equations.py",
line
621, in evaluate term_mode=term_mode) File "C:\Python27\lib\site-packages\sfepy\discrete\equations.py",
line
817, in evaluate ret_status=True) File "C:\Python27\lib\site-packages\sfepy\terms\terms.py", line 1337,
in
evaluate self.check_shapes(*args) File "C:\Python27\lib\site-packages\sfepy\terms\terms.py", line 1215,
in
check_shapes % term_str) ValueError: wrong arguments shapes for "ev_cauchy_stress.3.Omega(m.D,
u)"
term! (see above)
OK, glad you solved the problem!
r.
On 01/09/2017 02:50 PM, samyak jain wrote:
Hi Robert,
I did check it again and my mistake was that stiffness_from_youngpoisson with first parameter as 2 and hence (3,3). I have changed it now and it is fine and works perfectly fine. Thanks a lot.
Samyak
On Monday, 9 January 2017 13:47:10 UTC, samyak jain wrote:
Hi Robert,
Thanks for your reply. I have checked and it is (3,3). I am calculating D from stiffness_from_youngpoisson.
Thanks Samyak
On Monday, 9 January 2017 13:24:11 UTC, Robert Cimrman wrote:
Hi!
On 01/09/2017 01:27 PM, samyak jain wrote:
Hi all. I keep getting this error with the latest version of sfepy when
I
run the following lines. Could you guys please help.
strain =
pb.evaluate('ev_cauchy_strain.{dim}.Omega(u)'.format(dim=dims), mode='el_avg')
Note that the number after the term name has nothing to do with some dimension (assuming from your naming) - it is the numerical quadrature order.
The above line works fine.
stress = pb.evaluate('ev_cauchy_stress.3.Omega(m.D, u)',
copy_materials=False, mode='el_avg')
but the stress line always shows the error below. m is defined before
in the problem with 'D' value.
The D shape has to be (6, 6) in 3D or (3, 3) in 2D - can you check that?
r.
File "C:\Python27\lib\site-packages\sfepy\discrete\problem.py", line 1264, in evaluate sfepy: allowed argument shapes for term "ev_cauchy_stress.3.Omega(m.D,
u)":
sfepy: [{'material': 'S, S', 'parameter': 'D'}] mode=mode, dw_mode=dw_mode, term_mode=term_mode) File "C:\Python27\lib\site-packages\sfepy\discrete\evaluate.py", line 280, in eval_equations term_mode=term_mode, asm_obj=asm_obj) File "C:\Python27\lib\site-packages\sfepy\discrete\equations.py",
line
621, in evaluate term_mode=term_mode) File "C:\Python27\lib\site-packages\sfepy\discrete\equations.py",
line
817, in evaluate ret_status=True) File "C:\Python27\lib\site-packages\sfepy\terms\terms.py", line 1337,
in
evaluate self.check_shapes(*args) File "C:\Python27\lib\site-packages\sfepy\terms\terms.py", line 1215,
in
check_shapes % term_str) ValueError: wrong arguments shapes for "ev_cauchy_stress.3.Omega(m.D,
u)"
term! (see above)