Skip to content

Commit

Permalink
[Fix] Fix dist_wrapper in solver (#978)
Browse files Browse the repository at this point in the history
* do not wrap equation expression in distributed env

* update requirements.txt
  • Loading branch information
HydrogenSulfate authored Aug 20, 2024
1 parent 6854119 commit 46729fc
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
9 changes: 5 additions & 4 deletions ppsci/solver/solver.py
Original file line number Diff line number Diff line change
Expand Up @@ -517,10 +517,11 @@ def convert_expr(
for name in container.output_expr:
if isinstance(container.output_expr[name], sp.Basic):
container.output_expr[name] = funcs[ind]
if self.world_size > 1:
container.output_expr[name] = dist_wrapper(
container.output_expr[name]
)
# FIXME: Equation with parameter not support yet.
# if self.world_size > 1:
# container.output_expr[name] = dist_wrapper(
# container.output_expr[name]
# )
ind += 1

if self.constraint:
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ hydra-core
imageio
matplotlib
meshio==5.3.4
numpy>=1.20.0,<=1.23.1
numpy>=1.20.0,<2.0.0
pydantic>=2.5.0
pyevtk
pyyaml
Expand Down

0 comments on commit 46729fc

Please sign in to comment.