12#include "arcane/IMesh.h"
13#include "arcane/IApplication.h"
14#include "arcane/IParallelMng.h"
15#include "arcane/FactoryService.h"
16#include "arcane/ServiceFinder2.h"
17#include "arcane/SharedVariable.h"
18#include "arcane/CommonVariables.h"
19#include "arcane/utils/ScopedPtr.h"
20#include "arcane/AbstractService.h"
22#include "arcane/utils/IOnlineDebuggerService.h"
23#include "arcane/ITransferValuesParallelOperation.h"
25#include "arcane/hyoda/HyodaArc.h"
41void Hyoda::fetch_and_fill_data_to_be_dumped(ISubDomain* sd, UniqueIdType target_cell_uid){
43 debug()<<
"[fetch_and_fill_data_to_be_dumped] Fill data that will be broadcasted back in hook";
44 m_data->global_iteration=(
Int64)sd->commonVariables().globalIteration();
45 m_data->global_time=sd->commonVariables().globalTime();
46 m_data->global_deltat=sd->commonVariables().globalDeltaT();
47 m_data->global_cpu_time=sd->commonVariables().globalCPUTime();
51 LocalIdType target_cell_lid=targetCellIdToLocalId(sd, target_cell_uid);
54 if (target_cell_lid==NULL_ITEM_ID){
55 debug()<<
"[Hyoda::fetch_and_fill_data_to_be_dumped] NULL_ITEM_ID";
56 focused_cell=cells[0];
58 debug()<<
"[Hyoda::fetch_and_fill_data_to_be_dumped] lid "<<target_cell_lid<<
" (uid="<<target_cell_uid<<
")";
59 focused_cell=cells[target_cell_lid];
65 Real3 coord = nodes_coords[inode];
66 m_data->coords[i][0] = coord.x;
67 m_data->coords[i][1] = coord.y;
68 m_data->coords[i][2] = coord.z;
69 debug()<<
"[Hyoda::fetch_and_fill_data_to_be_dumped] node ("
70 << m_data->coords[i][0] <<
","
71 << m_data->coords[i][1] <<
","
72 << m_data->coords[i][2] <<
")"
77 if (!sd->parallelMng()->isParallel())
return;
81 if ((target_cell_lid!=NULL_ITEM_ID)
82 && (sd->parallelMng()->commRank()==m_gdbserver_rank)){
83 debug()<<
"[Hyoda::fetch_and_fill_data_to_be_dumped] CELL and SERVER";
87 if (target_cell_lid!=NULL_ITEM_ID){
88 debug()<<
"[Hyoda::fetch_and_fill_data_to_be_dumped] SENDing CELL";;
92 Real3 coord = nodes_coords[inode];
93 cell_nodes_coords[i].x=coord.x;
94 cell_nodes_coords[i].y=coord.y;
95 cell_nodes_coords[i].z=coord.z;
99 sd->parallelMng()->send(cell_nodes_coords.constView(),m_gdbserver_rank);
104 if (sd->parallelMng()->commRank()==m_gdbserver_rank){
105 debug()<<
"[Hyoda::fetch_and_fill_data_to_be_dumped] SERVEUR: recv from"<<m_data->target_cell_rank;
107 sd->parallelMng()->recv(cell_nodes_coords,m_data->target_cell_rank);
108 for(
int i=0;i<m_data->target_cell_nb_nodes;i++){
109 m_data->coords[i][0] = cell_nodes_coords[i].x;
110 m_data->coords[i][1] = cell_nodes_coords[i].y;
111 m_data->coords[i][2] = cell_nodes_coords[i].z;
Fichier de configuration d'Arcane.
Lecteur des fichiers de maillage via la bibliothèque LIMA.
UniqueArray< Real3 > Real3UniqueArray
Tableau dynamique à une dimension de vecteurs de rang 3.
ConstArrayView< ItemInternal * > ItemInternalList
Type de la liste interne des entités.
SharedMeshVariableScalarRefT< Node, Real3 > SharedVariableNodeReal3
Grandeur au noeud de type coordonnées.
Int32 LocalIdType
Type des entiers utilisés pour stocker les identifiants locaux des entités.