Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
lbmpy
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
lbmpy
Commits
3f3c98cd
Commit
3f3c98cd
authored
4 years ago
by
Michael Kuron
Browse files
Options
Downloads
Plain Diff
Merge branch 'FixPackageRequires' into 'master'
Fix package requires See merge request
!66
parents
65b2fd79
43ce20b9
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.gitignore
+2
-0
2 additions, 0 deletions
.gitignore
lbmpy/phasefield/nphase_nestler.py
+11
-4
11 additions, 4 deletions
lbmpy/phasefield/nphase_nestler.py
setup.py
+19
-3
19 additions, 3 deletions
setup.py
with
32 additions
and
7 deletions
.gitignore
+
2
−
0
View file @
3f3c98cd
...
@@ -16,3 +16,5 @@ _local_tmp
...
@@ -16,3 +16,5 @@ _local_tmp
doc/bibtex.json
doc/bibtex.json
RELEASE-VERSION
RELEASE-VERSION
/db
/db
/lbmpy/phasefield/simplex_projection.*.so
/lbmpy/phasefield/simplex_projection.c
\ No newline at end of file
This diff is collapsed.
Click to expand it.
lbmpy/phasefield/nphase_nestler.py
+
11
−
4
View file @
3f3c98cd
import
pyximport
try
:
import
pyximport
pyximport
.
install
(
language_level
=
3
)
from
lbmpy.phasefield.simplex_projection
import
simplex_projection_2d
# NOQA
except
ImportError
:
try
:
from
lbmpy.phasefield.simplex_projection
import
simplex_projection_2d
# NOQA
except
ImportError
:
raise
ImportError
(
"
neither pyximport nor binary module simplex_projection_2d available.
"
)
import
sympy
as
sp
import
sympy
as
sp
from
lbmpy.creationfunctions
import
create_lb_update_rule
from
lbmpy.creationfunctions
import
create_lb_update_rule
from
lbmpy.macroscopic_value_kernels
import
pdf_initialization_assignments
from
lbmpy.macroscopic_value_kernels
import
pdf_initialization_assignments
from
lbmpy.phasefield.analytical
import
chemical_potentials_from_free_energy
,
force_from_phi_and_mu
from
lbmpy.phasefield.analytical
import
chemical_potentials_from_free_energy
,
force_from_phi_and_mu
from
lbmpy.phasefield.cahn_hilliard_lbm
import
cahn_hilliard_lb_method
from
lbmpy.phasefield.cahn_hilliard_lbm
import
cahn_hilliard_lb_method
from
lbmpy.phasefield.simplex_projection
import
simplex_projection_2d
# NOQA
from
lbmpy.stencils
import
get_stencil
from
lbmpy.stencils
import
get_stencil
from
pystencils
import
Assignment
,
create_data_handling
,
create_kernel
from
pystencils
import
Assignment
,
create_data_handling
,
create_kernel
from
pystencils.fd
import
Diff
,
discretize_spatial
,
expand_diff_full
from
pystencils.fd
import
Diff
,
discretize_spatial
,
expand_diff_full
from
pystencils.fd.derivation
import
FiniteDifferenceStencilDerivation
from
pystencils.fd.derivation
import
FiniteDifferenceStencilDerivation
pyximport
.
install
(
language_level
=
3
)
def
forth_order_isotropic_discretize
(
field
):
def
forth_order_isotropic_discretize
(
field
):
second_neighbor_stencil
=
[(
i
,
j
)
second_neighbor_stencil
=
[(
i
,
j
)
...
...
This diff is collapsed.
Click to expand it.
setup.py
+
19
−
3
View file @
3f3c98cd
...
@@ -8,12 +8,17 @@ from importlib import import_module
...
@@ -8,12 +8,17 @@ from importlib import import_module
sys
.
path
.
insert
(
0
,
os
.
path
.
abspath
(
'
doc
'
))
sys
.
path
.
insert
(
0
,
os
.
path
.
abspath
(
'
doc
'
))
try
:
import
cython
# noqa
USE_CYTHON
=
True
except
ImportError
:
USE_CYTHON
=
False
quick_tests
=
[
quick_tests
=
[
#
'test_serial_scenarios.test_ldc_mrt',
'
test_serial_scenarios.test_ldc_mrt
'
,
'
test_serial_scenarios.test_channel_srt
'
,
'
test_serial_scenarios.test_channel_srt
'
,
]
]
class
SimpleTestRunner
(
distutils
.
cmd
.
Command
):
class
SimpleTestRunner
(
distutils
.
cmd
.
Command
):
"""
A custom command to run selected tests
"""
"""
A custom command to run selected tests
"""
...
@@ -43,7 +48,6 @@ class SimpleTestRunner(distutils.cmd.Command):
...
@@ -43,7 +48,6 @@ class SimpleTestRunner(distutils.cmd.Command):
for
test
in
quick_tests
:
for
test
in
quick_tests
:
self
.
_run_tests_in_module
(
test
)
self
.
_run_tests_in_module
(
test
)
try
:
try
:
sys
.
path
.
insert
(
0
,
os
.
path
.
abspath
(
'
doc
'
))
sys
.
path
.
insert
(
0
,
os
.
path
.
abspath
(
'
doc
'
))
from
version_from_git
import
version_number_from_git
from
version_from_git
import
version_number_from_git
...
@@ -54,6 +58,14 @@ try:
...
@@ -54,6 +58,14 @@ try:
except
ImportError
:
except
ImportError
:
version
=
open
(
'
RELEASE-VERSION
'
,
'
r
'
).
read
()
version
=
open
(
'
RELEASE-VERSION
'
,
'
r
'
).
read
()
def
cython_extensions
(
*
extensions
):
from
distutils.extension
import
Extension
ext
=
'
.pyx
'
if
USE_CYTHON
else
'
.c
'
result
=
[
Extension
(
e
,
[
e
.
replace
(
'
.
'
,
'
/
'
)
+
ext
])
for
e
in
extensions
]
if
USE_CYTHON
:
from
Cython.Build
import
cythonize
result
=
cythonize
(
result
,
language_level
=
3
)
return
result
def
readme
():
def
readme
():
with
open
(
'
README.md
'
)
as
f
:
with
open
(
'
README.md
'
)
as
f
:
...
@@ -71,6 +83,9 @@ setup(name='lbmpy',
...
@@ -71,6 +83,9 @@ setup(name='lbmpy',
url
=
'
https://i10git.cs.fau.de/pycodegen/lbmpy/
'
,
url
=
'
https://i10git.cs.fau.de/pycodegen/lbmpy/
'
,
packages
=
[
'
lbmpy
'
]
+
[
'
lbmpy.
'
+
s
for
s
in
find_packages
(
'
lbmpy
'
)],
packages
=
[
'
lbmpy
'
]
+
[
'
lbmpy.
'
+
s
for
s
in
find_packages
(
'
lbmpy
'
)],
install_requires
=
[
'
pystencils
'
,
'
sympy>=1.2
'
,
'
numpy>=1.11.0
'
],
install_requires
=
[
'
pystencils
'
,
'
sympy>=1.2
'
,
'
numpy>=1.11.0
'
],
package_data
=
{
'
lbmpy
'
:
[
'
phasefield/simplex_projection.pyx
'
,
'
phasefield/simplex_projection.c
'
]},
ext_modules
=
cython_extensions
(
"
lbmpy.phasefield.simplex_projection
"
),
classifiers
=
[
classifiers
=
[
'
Development Status :: 4 - Beta
'
,
'
Development Status :: 4 - Beta
'
,
'
Framework :: Jupyter
'
,
'
Framework :: Jupyter
'
,
...
@@ -89,6 +104,7 @@ setup(name='lbmpy',
...
@@ -89,6 +104,7 @@ setup(name='lbmpy',
'
ipy_table
'
,
'
imageio
'
,
'
jupyter
'
,
'
pyevtk
'
],
'
ipy_table
'
,
'
imageio
'
,
'
jupyter
'
,
'
pyevtk
'
],
'
doc
'
:
[
'
sphinx
'
,
'
sphinx_rtd_theme
'
,
'
nbsphinx
'
,
'
doc
'
:
[
'
sphinx
'
,
'
sphinx_rtd_theme
'
,
'
nbsphinx
'
,
'
sphinxcontrib-bibtex
'
,
'
sphinx_autodoc_typehints
'
,
'
pandoc
'
],
'
sphinxcontrib-bibtex
'
,
'
sphinx_autodoc_typehints
'
,
'
pandoc
'
],
'
phasefield
'
:
[
'
Cython
'
]
},
},
cmdclass
=
{
cmdclass
=
{
'
quicktest
'
:
SimpleTestRunner
'
quicktest
'
:
SimpleTestRunner
...
...
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