Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pyopencl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Andreas Klöckner
pyopencl
Commits
401d0933
Commit
401d0933
authored
12 years ago
by
Andreas Klöckner
Browse files
Options
Downloads
Patches
Plain Diff
Some test fixes/loosened error bounds.
parent
dfb4152c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
test/test_algorithm.py
+9
-19
9 additions, 19 deletions
test/test_algorithm.py
test/test_clmath.py
+2
-2
2 additions, 2 deletions
test/test_clmath.py
with
11 additions
and
21 deletions
test/test_algorithm.py
+
9
−
19
View file @
401d0933
...
...
@@ -29,21 +29,12 @@ import pytools.test
from
pytools
import
memoize
from
test_array
import
general_clrand
def
have_cl
():
try
:
import
pyopencl
return
True
except
:
return
False
if
have_cl
():
import
pyopencl
as
cl
import
pyopencl.array
as
cl_array
import
pyopencl.tools
as
cl_tools
from
pyopencl.tools
import
pytest_generate_tests_for_pyopencl
\
as
pytest_generate_tests
from
pyopencl.characterize
import
has_double_support
import
pyopencl
as
cl
import
pyopencl.array
as
cl_array
import
pyopencl.tools
as
cl_tools
from
pyopencl.tools
import
pytest_generate_tests_for_pyopencl
\
as
pytest_generate_tests
from
pyopencl.characterize
import
has_double_support
...
...
@@ -579,6 +570,9 @@ def test_partition(ctx_factory):
@pytools.test.mark_test.opencl
def
test_unique
(
ctx_factory
):
from
pytest
import
importorskip
importorskip
(
"
mako
"
)
context
=
ctx_factory
()
queue
=
cl
.
CommandQueue
(
context
)
...
...
@@ -835,10 +829,6 @@ def test_key_value_sorter(ctx_factory):
if
__name__
==
"
__main__
"
:
# make sure that import failures get reported, instead of skipping the
# tests.
import
pyopencl
as
cl
import
sys
if
len
(
sys
.
argv
)
>
1
:
exec
(
sys
.
argv
[
1
])
...
...
This diff is collapsed.
Click to expand it.
test/test_clmath.py
+
2
−
2
View file @
401d0933
...
...
@@ -118,8 +118,8 @@ if have_cl():
test_cos
=
make_unary_function_test
(
"
cos
"
,
(
-
10
,
10
),
2e-7
,
use_complex
=
2e-2
)
test_asin
=
make_unary_function_test
(
"
asin
"
,
(
-
0.9
,
0.9
),
5e-7
)
test_acos
=
make_unary_function_test
(
"
acos
"
,
(
-
0.9
,
0.9
),
5e-7
)
test_tan
=
make_unary_function_test
(
"
tan
"
,
(
-
math
.
pi
/
2
+
0.1
,
math
.
pi
/
2
-
0.1
),
2
e-5
,
use_complex
=
True
)
test_tan
=
make_unary_function_test
(
"
tan
"
,
(
-
math
.
pi
/
2
+
0.1
,
math
.
pi
/
2
-
0.1
),
4
e-5
,
use_complex
=
True
)
test_atan
=
make_unary_function_test
(
"
atan
"
,
(
-
10
,
10
),
2e-7
)
test_sinh
=
make_unary_function_test
(
"
sinh
"
,
(
-
3
,
3
),
2e-6
,
use_complex
=
2e-3
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment