I was debugging in debug mode. Just changed make to release mode and the error gone! Why running in debug mode causes this error?
As for the side note, that's very helpful! I worried about the write&read mesh price but don't know what techniques can I use. That's exactly what I want. Thank you. Best, Wayne 在2022年11月29日星期二 UTC+8 12:30:15<Wolfgang Bangerth> 写道: > > > The error is from compute_component_wise on level = 0, the result it > returns > > don't equal to dof_handler.n_dofs(level). > > I added a MPI_Barrier between first and second loop but error is not > eliminated. > > Snipaste_2022-11-28_12-53-02.png > > I do not see this error. Are you running in debug mode? And with how many > MPI > processes? > > As a side note: The detour by writing the data to a file and then reading > it > again is very inefficient, in particular if you have many MPI processes. > If > you want to use GridOut/GridIn, let the former write the data into an > object > of type std::ostringstream, then use Utilities::MPI::broadcast() to send > the > string you get out of std::ostringstream to the other processes, and give > it > to a std::istringstream object. Then use GridIn on the std::istringstream > object. This way, no data transfer to or from disk is necessary -- it all > happens in memory. > > Best > Wolfgang > > -- > ------------------------------------------------------------------------ > Wolfgang Bangerth email: bang...@colostate.edu > www: http://www.math.colostate.edu/~bangerth/ > > > -- The deal.II project is located at http://www.dealii.org/ For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en --- You received this message because you are subscribed to the Google Groups "deal.II User Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to dealii+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/dealii/9be828ee-3e6d-4cee-ae54-6fcf390752c6n%40googlegroups.com.