Open soumyadipghosh opened 5 years ago
Yes, gko::matrix::Dense<ValueType>
as it is for the local_solution
should be fine.
I added the following line in schwarz_solver.hpp
for declaration:
std::shared_ptr<gko::matrix::Dense<ValueType>> boundary_solution;
Then, in initialize.cpp
, I do something like this:
boundary_solution = vec::create(settings.executor, gko::dim<2>(local_size * overlap_size * 4, 1));
. Correct me if I am wrong.
Why do you need the size to be local_size * overlap_size * 4
?
size of domain across one dimension overlap at each boundary 4 boundary PEs (at max) for every PE.
I was going through exchange_boundary_onesided
in schwarz_solver.cpp
. The MPI_Put
routines don't have lock or unlock before and after them. How do you do that ? Is it the MPI_Win_lock_all
in setup_windows
?
Yes, the setup_windows
just does the MPI_Win_lock_all
and unlocks it later in the clear
from the Communicate class. I did initially have the single locks just before and after puts, but it seemed to be slower so I removed them. But if you want to add them for your case feel free to test them out and see if it is slower or faster in your case.
Another small note: I manage the formatting by using clang-format
. I think it does a good job of keeping a uniform formatting throughout the whole code. The configuration file that I use is also in the root of this git repo. It would be nice if you too could you use it before you commit the code. Thanks.
I made some changes to schwarz_solver.cpp
. I also did a git merge develop
to merge all changes you made to develop. Now when I go to compile the event-based
branch, I get the following errors:
develop
should work now.
I get the following error now:
schwarz-lib/source/schwarz_solver.cpp:66:19: error: ‘class gko::OmpExecutor’ has no member named ‘get_exec_info’ ->get_exec_info();
Is it a problem with the Ginkgo version I have (1.0.0) ?
I think you actually need the branch expt-develop
from Ginkgo right now.
So the expt-develop
is for version 1.1.0? Is get_exec_info
a method in 1.1.0 ?
No, expt-develop
has nothing to do with the Ginkgo release versions. Ginkgo 1.1.0
can be found in the most up to date master branch of Ginkgo. expt-develop
on the other end has experimental features (machine topology information and more) which this project uses.
Yes, @tcojean is correct. You will need to checkout the expt-develop
branch now as that contains the get_exec_info
method.
Ok, develop
compiles now, thanks @tcojean.
How do I initialize all values of a gko::matrix::Dense
type matrix to 0
, e.g, in line 797 in develop branch of schwarz_solver.cpp
?
Edit: I can initialize the matrix using get_values() after declaring it but is there a built-in function for that?
For doing event-based communication, we need a variable called
boundary_solution
in addition tolocal_solution
as defined inschwarz_solver.hpp
. I am wondering what would be the datatype of that variable. For a 2D problem, each PE has 4 boundaries, each of which is a vector - so making it agko::matrix::Dense
is okay ?