Skip to content

Commit 24a3f4a

Browse files
committed
Add NpyFile debug output
1 parent 17f732c commit 24a3f4a

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

Source/Processors/RecordNode/BinaryFormat/NpyFile.cpp

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,19 @@ bool NpyFile::openFile(String path)
7979
// output stream buffer size defaults to 32768 bytes, but is irrelevant because
8080
// each updateHeader() call triggers a m_file->flush() to disk:
8181
m_file = file.createOutputStream();
82+
83+
if (m_file == nullptr)
84+
{
85+
LOGD("FAILED to open file @", path);
86+
}
87+
else
88+
{
89+
String pad = "";
90+
for (int i = 0; i < 162 - path.length(); i++)
91+
pad += " ";
92+
LOGD("Successfully opened file @", path, pad, m_file);
93+
}
94+
8295
if (!m_file)
8396
return false;
8497

@@ -156,6 +169,7 @@ void NpyFile::writeHeader(const Array<NpyType>& typeList)
156169

157170
void NpyFile::updateHeader()
158171
{
172+
159173
if (true)
160174
{
161175
// overwrite the shape part of the header - even without explicitly calling

0 commit comments

Comments
 (0)