Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
pystencils
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
itischler
pystencils
Commits
699144dd
Commit
699144dd
authored
3 years ago
by
Michael Kuron
Browse files
Options
Downloads
Plain Diff
Merge branch 'RemoveWarning' into 'master'
Remove gmpy workaround See merge request
!255
parents
cb9cccfb
1e7a1e6f
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
pystencils/__init__.py
+0
-1
0 additions, 1 deletion
pystencils/__init__.py
pystencils/session.py
+0
-1
0 additions, 1 deletion
pystencils/session.py
pystencils/sympy_gmpy_bug_workaround.py
+0
-18
0 additions, 18 deletions
pystencils/sympy_gmpy_bug_workaround.py
with
0 additions
and
20 deletions
pystencils/__init__.py
+
0
−
1
View file @
699144dd
"""
Module to generate stencil kernels in C or CUDA using sympy expressions and call them as Python functions
"""
"""
Module to generate stencil kernels in C or CUDA using sympy expressions and call them as Python functions
"""
from
.
import
sympy_gmpy_bug_workaround
# NOQA
from
.
import
fd
from
.
import
fd
from
.
import
stencil
as
stencil
from
.
import
stencil
as
stencil
from
.assignment
import
Assignment
,
assignment_from_stencil
from
.assignment
import
Assignment
,
assignment_from_stencil
...
...
This diff is collapsed.
Click to expand it.
pystencils/session.py
+
0
−
1
View file @
699144dd
...
@@ -4,6 +4,5 @@ import sympy as sp
...
@@ -4,6 +4,5 @@ import sympy as sp
import
pystencils
as
ps
import
pystencils
as
ps
import
pystencils.jupyter
import
pystencils.jupyter
import
pystencils.plot
as
plt
import
pystencils.plot
as
plt
import
pystencils.sympy_gmpy_bug_workaround
__all__
=
[
'
sp
'
,
'
np
'
,
'
ps
'
,
'
plt
'
]
__all__
=
[
'
sp
'
,
'
np
'
,
'
ps
'
,
'
plt
'
]
This diff is collapsed.
Click to expand it.
pystencils/sympy_gmpy_bug_workaround.py
deleted
100644 → 0
+
0
−
18
View file @
cb9cccfb
# Disable gmpy backend until this bug is resolved if joblib serialize
# See https://github.com/sympy/sympy/pull/13530
import
os
import
warnings
os
.
environ
[
'
MPMATH_NOGMPY
'
]
=
'
1
'
try
:
import
mpmath.libmp
# In case the user has imported sympy first, then pystencils
if
mpmath
.
libmp
.
BACKEND
==
'
gmpy
'
:
warnings
.
warn
(
"
You are using the gmpy backend. You might encounter an error
'
argument is not an mpz sympy
'
.
"
"
This is due to a known bug in sympy/gmpy library.
"
"
To prevent this, import pystencils first then sympy or set the environment variable
"
"
MPMATH_NOGMPY=1
"
)
except
ImportError
:
pass
__all__
=
[]
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