adjustment to tolerances

Rodrigues test is 'prone' to fail due to diverging tangens(pi/2).
Happens only with a very low chance
This commit is contained in:
Martin Diehl 2020-01-14 10:57:50 +01:00
parent 3afc011a58
commit 18d6d364ec
1 changed files with 4 additions and 4 deletions

View File

@ -7,7 +7,7 @@ import damask
from damask import Rotation
from damask import Orientation
n = 1000
n = 100000
@pytest.fixture
def default():
@ -45,17 +45,17 @@ class TestRotation:
def test_Homochoric(self,default):
for rot in default:
assert np.allclose(rot.asRodrigues(),
Rotation.fromHomochoric(rot.asHomochoric()).asRodrigues(),rtol=5.e-5)
Rotation.fromHomochoric(rot.asHomochoric()).asRodrigues(),rtol=1.e-4)
def test_Cubochoric(self,default):
for rot in default:
assert np.allclose(rot.asHomochoric(),
Rotation.fromCubochoric(rot.asCubochoric()).asHomochoric(),rtol=5.e-5)
Rotation.fromCubochoric(rot.asCubochoric()).asHomochoric())
def test_Quaternion(self,default):
for rot in default:
assert np.allclose(rot.asCubochoric(),
Rotation.fromQuaternion(rot.asQuaternion()).asCubochoric(),rtol=5.e-5)
Rotation.fromQuaternion(rot.asQuaternion()).asCubochoric())
@pytest.mark.parametrize('model',['Bain','KS','GT','GT_prime','NW','Pitsch'])