Skip to content

Commit b2e8f6a

Browse files
committed
removed output
1 parent 9f7196d commit b2e8f6a

File tree

7 files changed

+49
-51
lines changed

7 files changed

+49
-51
lines changed

source/adios2/engine/julea-kv/JuleaKVReader.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ class JuleaKVReader : public Engine
8787
static std::mutex m_Mutex;
8888

8989
int m_Verbosity = 0; // change from 0 to 5 for debugging
90-
int m_Penguin = 42; // change for debugging info from 0 to 42
90+
int m_Penguin = 0; // change for debugging info from 0 to 42
9191
int m_ReaderRank; // my rank in the readers' comm
9292
int m_SizeMPI = 1; ///< current MPI processes size
9393

source/adios2/engine/julea-kv/JuleaKVWriter.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ void JuleaKVWriter::EndStep()
119119
m_CurrentBlockID = 0;
120120

121121
m_Comm.Barrier();
122-
if (m_WriterRank == 0)
122+
if ((m_WriterRank == 0) && (m_Verbosity == 5))
123123
{
124124
std::cout << "______________EndStep _____________________ step = "
125125
<< (m_CurrentStep - 1) << "\n " << std::endl;
@@ -237,13 +237,13 @@ void JuleaKVWriter::Init()
237237

238238
if (m_WriterRank == 0)
239239
{
240-
std::cout << "JKV Writer (" << m_WriterRank << ") : InitDBSchemas()\n";
240+
// std::cout << "JKV Writer (" << m_WriterRank << ") : InitDBSchemas()\n";
241241
InitParameters();
242242

243243
m_JuleaKVInteractionWriter.InitKV(m_ProjectNamespace,
244244
m_IsOriginalFormat);
245-
std::cout << "JKV Writer (" << m_WriterRank
246-
<< ") : InitKV finished()\n";
245+
// std::cout << "JKV Writer (" << m_WriterRank
246+
// << ") : InitKV finished()\n";
247247
}
248248
}
249249

source/adios2/engine/julea-kv/JuleaKVWriter.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ class JuleaKVWriter : public Engine
6868
JSemantics *m_JuleaSemantics;
6969
StepMode m_StepMode = StepMode::Append;
7070

71-
int m_Verbosity = 5; // change for debugging info from 0 to 5
71+
int m_Verbosity = 0; // change for debugging info from 0 to 5
7272
int m_Penguin = 0; // change for debugging info from 0 to 42
7373
int m_WriterRank; // my rank in the writers' comm
7474

source/adios2/engine/julea-kv/JuleaKVWriter.tcc

Lines changed: 21 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -240,11 +240,11 @@ void JuleaKVWriter::ComputeGlobalDimensions(Variable<T> &variable)
240240

241241
if (m_Comm.Size() == testNumberProcesses)
242242
{
243-
std::cout << "wuhu: gleich groß \n";
243+
// std::cout << "wuhu: gleich groß \n";
244244
}
245245

246-
std::cout << "X = " << m_JuleaCDO.m_numberBlocksX << "\n";
247-
std::cout << "Y = " << m_JuleaCDO.m_numberBlocksY << "\n";
246+
// std::cout << "X = " << m_JuleaCDO.m_numberBlocksX << "\n";
247+
// std::cout << "Y = " << m_JuleaCDO.m_numberBlocksY << "\n";
248248
}
249249

250250
template <class T>
@@ -326,21 +326,28 @@ void JuleaKVWriter::PutSyncToJulea(Variable<T> &variable, const T *data,
326326
variable, m_ProjectNamespace, m_Name, variable.m_Name,
327327
m_CurrentStep, m_CurrentBlockID, m_IsOriginalFormat);
328328

329-
// TODO: seems like key-value backend cannot handle parallel access ->
329+
// TODO: only for SQLite Backend seems like key-value backend cannot handle parallel access ->
330330
// master has to do everything
331331
// -> m_CurrentBlockID replaced by i
332-
for (int i = 0; i < m_Comm.Size(); i++)
333-
{
334-
/** put block metadata to DB */
335-
m_JuleaKVInteractionWriter.PutBlockMetadataToJulea(
336-
variable, m_ProjectNamespace, m_Name, variable.m_Name,
337-
m_CurrentStep, i, blockInfo, blockMin, blockMax, blockMean,
338-
blockSum, blockVar, entryID, m_IsOriginalFormat);
339-
// m_CurrentBlockID, blockInfo, blockMin, blockMax, blockMean,
340-
// blockSum,
341-
}
332+
// for (int i = 0; i < m_Comm.Size(); i++)
333+
// {
334+
// /** put block metadata to DB */
335+
// m_JuleaKVInteractionWriter.PutBlockMetadataToJulea(
336+
// variable, m_ProjectNamespace, m_Name, variable.m_Name,
337+
// m_CurrentStep, i, blockInfo, blockMin, blockMax, blockMean,
338+
// blockSum, blockVar, entryID, m_IsOriginalFormat);
339+
// // m_CurrentBlockID, blockInfo, blockMin, blockMax, blockMean,
340+
// // blockSum,
341+
// }
342342
}
343343

344+
/** put block metadata to DB */
345+
m_JuleaKVInteractionWriter.PutBlockMetadataToJulea(
346+
variable, m_ProjectNamespace, m_Name, variable.m_Name,
347+
m_CurrentStep, m_CurrentBlockID, blockInfo, blockMin, blockMax, blockMean,
348+
blockSum, blockVar, entryID, m_IsOriginalFormat);
349+
350+
344351
/** put data to object store */
345352
m_JuleaKVInteractionWriter.PutVariableDataToJulea(
346353
variable, data, m_ProjectNamespace, m_Name, m_CurrentStep,

source/adios2/toolkit/interop/julea/JuleaInteraction.tcc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ void JuleaInteraction::GetVariableDataFromJulea(
129129
if (isKV)
130130
{
131131
auto stepBlockID = g_strdup_printf("%lu_%lu", step, ID);
132-
std::cout << "stepBlockID: " << stepBlockID << "\n";
132+
// std::cout << "stepBlockID: " << stepBlockID << "\n";
133133
dataObject = j_object_new(stringDataObject, stepBlockID);
134134
}
135135
else

source/adios2/toolkit/interop/julea/KeyValue/JuleaKVInteractionReader.cpp

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ void JuleaKVInteractionReader::InitVariable(
6565
size_t numberSteps, ShapeID shapeID, bool isReadAsJoined,
6666
bool isReadAsLocalValue, bool isRandomAccess, bool isSingleValue)
6767
{
68-
std::cout << "----- InitVariable --- " << varName << std::endl;
68+
// std::cout << "----- InitVariable --- " << varName << std::endl;
6969
const adios2::DataType type(io->InquireVariableType(varName));
7070

7171
// std::cout << "type(io->InquireVariableType(varName): " << type <<
@@ -202,7 +202,7 @@ void JuleaKVInteractionReader::DefineVariableInEngineIO(
202202
ShapeID shapeID, Dims shape, Dims start, Dims count, bool constantDims,
203203
bool isLocalValue)
204204
{
205-
std::cout << "----- DefineVariableInEngineIO --- " << varName << std::endl;
205+
// std::cout << "----- DefineVariableInEngineIO --- " << varName << std::endl;
206206

207207
// std::cout << "shapeID: " << shapeID << "\n";
208208
// std::cout << "shape size: " << shape.size() << "\n";
@@ -283,14 +283,14 @@ void JuleaKVInteractionReader::GetVarNamesFromJulea(
283283

284284
if (err != 0)
285285
{
286-
std::cout << "j_batch_execute failed in GetNamesFromJulea. "
287-
<< std::endl;
286+
// std::cout << "j_batch_execute failed in GetNamesFromJulea. "
287+
// << std::endl;
288288
}
289289

290290
if (valueLen == 0)
291291
{
292-
std::cout << "WARNING: The kv store: " << kvName << " is empty!"
293-
<< std::endl;
292+
// std::cout << "WARNING: The kv store: " << kvName << " is empty!"
293+
// << std::endl;
294294

295295
*varCount = 0;
296296
free(namesBuf);
@@ -525,7 +525,7 @@ void JuleaKVInteractionReader::ParseVariableFromBSON(
525525

526526
gchar const *key;
527527

528-
std::cout << "----- ParseVariableFromBSON --- " << std::endl;
528+
// std::cout << "----- ParseVariableFromBSON --- " << std::endl;
529529
if (bson_iter_init(&bIter, bsonMetadata))
530530
{
531531
// std::cout << "++ Julea Client Logic: Bson iterator is valid"
@@ -703,8 +703,8 @@ void JuleaKVInteractionReader::GetVariableMetadataFromJulea(
703703
const std::string varName, bson_t *bsonMetadata)
704704
// const std::string varName, gpointer *buffer, guint32 *buffer_len)
705705
{
706-
std::cout << "----- GetVariableMetadataFromJulea --- " << varName
707-
<< std::endl;
706+
// std::cout << "----- GetVariableMetadataFromJulea --- " << varName
707+
// << std::endl;
708708

709709
int err = 0;
710710
JDBType type;
@@ -789,7 +789,7 @@ void JuleaKVInteractionReader::InitVariablesFromKV(
789789
const std::string projectNamespace, const std::string fileName,
790790
core::IO *io, core::Engine &engine)
791791
{
792-
std::cout << "--- InitVariablesFromKV ---" << std::endl;
792+
// std::cout << "--- InitVariablesFromKV ---" << std::endl;
793793
int err = 0;
794794
char *varName;
795795
bson_t bsonMetadata;
@@ -811,7 +811,7 @@ void JuleaKVInteractionReader::InitVariablesFromKV(
811811
{
812812
// if (m_Verbosity == 5)
813813
// {
814-
std::cout << "++ InitVariables: no variables stored in KV" << std::endl;
814+
// std::cout << "++ InitVariables: no variables stored in KV" << std::endl;
815815
// }
816816
}
817817
else

source/adios2/toolkit/interop/julea/KeyValue/JuleaKVInteractionWriter.tcc

Lines changed: 10 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -122,11 +122,11 @@ void JuleaKVInteractionWriter::ParseVariableToBSON(core::Variable<T> &variable,
122122
bson_t *bsonMetadata,
123123
size_t currentStep)
124124
{
125-
std::cout << "_____________________________________________" << std::endl;
125+
// std::cout << "_____________________________________________" << std::endl;
126126
// std::cout << "Test" << std::endl;
127127
T min;
128128
T max;
129-
std::cout << "-- ParseVariableToBSON \n";
129+
// std::cout << "-- ParseVariableToBSON \n";
130130

131131
// std::cout << "-- Variable bsonMetadata length: " << bsonMetadata->len
132132
// << std::endl;
@@ -193,8 +193,6 @@ void JuleaKVInteractionWriter::ParseVariableToBSON(core::Variable<T> &variable,
193193

194194
bson_append_int64(bsonMetadata, "steps_start", -1, variable.m_StepsStart);
195195
bson_append_int64(bsonMetadata, "steps_count", -1, variable.m_StepsCount);
196-
// std::cout << "DEBUG: steps_start" << variable.m_StepsStart << std::endl;
197-
// std::cout << "DEBUG: steps_count" << variable.m_StepsCount << std::endl;
198196
bson_append_int64(bsonMetadata, "number_steps", -1, numberSteps);
199197
// std::cout << "numberSteps: " << numberSteps << "\n";
200198
for (guint i = 0; i < numberSteps; ++i)
@@ -241,11 +239,11 @@ void JuleaKVInteractionWriter::ParseBlockToBSON(core::Variable<T> &variable,
241239
bson_t *bsonMetadata,
242240
T blockMin, T blockMax)
243241
{
244-
std::cout << "_____________________________________________" << std::endl;
242+
// std::cout << "_____________________________________________" << std::endl;
245243
T min;
246244
T max;
247245

248-
std::cout << "-- ParseBlockToBSON \n";
246+
// std::cout << "-- ParseBlockToBSON \n";
249247
// std::cout << "-- bsonMetadata length: " << bsonMetadata->len <<
250248
// std::endl;
251249
uint data_size = 0;
@@ -319,7 +317,7 @@ void JuleaKVInteractionWriter::PutVarNameToJulea(
319317
std::string const projectNamespace, std::string const fileName,
320318
std::string const varName)
321319
{
322-
std::cout << "-- PutVarNameToJulea \n";
320+
// std::cout << "-- PutVarNameToJulea \n";
323321

324322
bool err = false;
325323
guint32 valueLen = 0;
@@ -337,12 +335,10 @@ void JuleaKVInteractionWriter::PutVarNameToJulea(
337335

338336
/** store all variable names for a file = namespace */
339337
auto varNames = j_kv_new(completeNamespace, fileName.c_str());
340-
std::cout << "debug 1\n";
338+
341339
j_kv_get(varNames, &namesBuf, &valueLen, batch);
342-
std::cout << "debug 2\n";
343340
err = j_batch_execute(batch);
344341
// g_assert_true(j_batch_execute(batch) == true);
345-
std::cout << "debug 3\n";
346342

347343
// JULEA does not return an error value but TRUE or FALSE
348344
if (err == false)
@@ -361,7 +357,6 @@ void JuleaKVInteractionWriter::PutVarNameToJulea(
361357
if (valueLen == 0)
362358
{
363359
bsonNames = bson_new();
364-
std::cout << "valueLen = 0 \n";
365360
}
366361
else
367362
{
@@ -380,8 +375,8 @@ void JuleaKVInteractionWriter::PutVarNameToJulea(
380375
}
381376
else
382377
{
383-
std::cout << "++ Julea Interaction Writer: " << varName
384-
<< " already in kv store. " << std::endl;
378+
// std::cout << "++ Julea Interaction Writer: " << varName
379+
// << " already in kv store. " << std::endl;
385380
}
386381

387382
// bson_iter_init_find(&bIter2, bsonNames, "T");
@@ -393,15 +388,11 @@ void JuleaKVInteractionWriter::PutVarNameToJulea(
393388
// key = bson_iter_key (&bIter2);
394389
// value = bson_iter_value (&bIter2);
395390
// std::cout << "key: " << key << " value: " << value << "\n";
396-
std::cout << "debug 4\n";
397391

398392
namesBuf = g_memdup2(bson_get_data(bsonNames), bsonNames->len);
399-
std::cout << "debug 5\n";
400393
j_kv_put(varNames, namesBuf, bsonNames->len, g_free, batch2);
401394
// err = j_batch_execute(batch2);
402-
std::cout << "debug 6\n";
403395
g_assert_true(j_batch_execute(batch2) == true);
404-
std::cout << "debug 7\n";
405396

406397
// free(namesBuf); //TODO: why does this lead to segfaults?
407398
bson_destroy(bsonNames);
@@ -417,7 +408,7 @@ void JuleaKVInteractionWriter::PutVariableMetadataToJulea(
417408
const std::string fileName, const std::string varName, size_t step,
418409
size_t block, bool original)
419410
{
420-
std::cout << "-- PutVariableMetadataToJulea \n";
411+
// std::cout << "-- PutVariableMetadataToJulea \n";
421412

422413
auto bsonMetadata = bson_new();
423414
auto semantics = j_semantics_new(J_SEMANTICS_TEMPLATE_DEFAULT);
@@ -447,7 +438,7 @@ void JuleaKVInteractionWriter::PutBlockMetadataToJulea(
447438
T &blockMin, T &blockMax, T &blockMean, T &blockSum, T &blockVar,
448439
uint32_t &entryID, bool original)
449440
{
450-
std::cout << "-- PutBlockMetadataToJulea \n";
441+
// std::cout << "-- PutBlockMetadataToJulea \n";
451442

452443
auto bsonMetadata = bson_new();
453444
auto semantics = j_semantics_new(J_SEMANTICS_TEMPLATE_DEFAULT);

0 commit comments

Comments
 (0)