<div dir="ltr">I think you can change the value in the source code in darshan-runtime (in darshan.h there is a variable, but I suppose darshan developers can provide a more appropriate solution). I had a similar case, but I decided to filter folders by using the DARSHAN_EXCLUDE_DIRS environment variable and only trace files open by the user's application and not trace files related to the python libraries.<div>Regards,</div><div>Sandra.-<br><div><br><div><br></div></div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, 9 Jul 2020 at 00:09, Devarajan, Hariharan <<a href="mailto:hdevarajan@anl.gov">hdevarajan@anl.gov</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div lang="EN-US">
<div class="gmail-m_7603816165024406521WordSection1">
<p class="MsoNormal">I see. There are 1024 files exactly in the darshan trace. What is the limit of the total number of files? Can we increase it?</p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">Hari</p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<div style="border-right:none;border-bottom:none;border-left:none;border-top:1pt solid rgb(225,225,225);padding:3pt 0in 0in">
<p class="MsoNormal" style="border:none;padding:0in"><b>From: </b><a href="mailto:smendez.fi.unju@gmail.com" target="_blank">Sandra A. Mendez</a><br>
<b>Sent: </b>Wednesday, July 8, 2020 2:49 PM<br>
<b>To: </b><a href="mailto:hdevarajan@anl.gov" target="_blank">Devarajan, Hariharan</a><br>
<b>Cc: </b><a href="mailto:ssnyder@mcs.anl.gov" target="_blank">Snyder, Shane</a>; <a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">
darshan-users@lists.mcs.anl.gov</a><br>
<b>Subject: </b>Re: [Darshan-users] Darshan not tracing with tensorflow import.</p>
</div>
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<div>
<p class="MsoNormal">Only a comment, Could be when you import tensorflow the number of files to trace exceeds the maximum files to trace defined by Darshan? This could be the reason that you don't see the file logs that you comment.<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">Sandra.-<u></u><u></u></p>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
</div>
</div>
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<div>
<p class="MsoNormal">On Wed, 8 Jul 2020 at 21:38, Devarajan, Hariharan <<a href="mailto:hdevarajan@anl.gov" target="_blank">hdevarajan@anl.gov</a>> wrote:<u></u><u></u></p>
</div>
<blockquote style="border-top:none;border-right:none;border-bottom:none;border-left:1pt solid rgb(204,204,204);padding:0in 0in 0in 6pt;margin-left:4.8pt;margin-right:0in">
<div>
<div>
<p class="MsoNormal">Here are the reproducers. The working one has the tensorflow import commented (1<sup>st</sup> line). If u uncomment that, the hdf5 file and npz file stops getting traced. Rest of
the py files are traced so Darshan is working.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Hari</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal"> </p>
<div style="border-right:none;border-bottom:none;border-left:none;border-top:1pt solid rgb(225,225,225);padding:3pt 0in 0in">
<p class="MsoNormal"><b>From:
</b><a href="mailto:ssnyder@mcs.anl.gov" target="_blank">Snyder, Shane</a><br>
<b>Sent: </b>Wednesday, July 8, 2020 10:27 AM<br>
<b>To: </b><a href="mailto:hdevarajan@anl.gov" target="_blank">Devarajan, Hariharan</a><br>
<b>Cc: </b><a href="mailto:laytonjb@gmail.com" target="_blank">Jeffrey Layton</a>;
<a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">darshan-users@lists.mcs.anl.gov</a><br>
<b>Subject: </b>Re: [Darshan-users] Darshan not tracing with tensorflow import.</p>
</div>
<p class="MsoNormal"> </p>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">I see. Thanks for the clarification.</span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"> </span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">The only issue I'm aware of that currently causes us to lose some log data is in the case of applications calling fork(). Maybe that or
something similar is happening in the import of tensorflow, with the h5/numpy I/O then happening in the child process?</span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"> </span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">I can try to reproduce the issue to see if I can get a better idea of what's happening. We'd like to make sure tensorflow use cases work,
but admittedly haven't really tested it.</span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"> </span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">--Shane</span></p>
</div>
<p class="MsoNormal"><img border="0" width="555" height="2" style="width: 5.7833in; height: 0.025in;" id="gmail-m_7603816165024406521gmail-m_4618596293159926224Horizontal_x0020_Line_x0020_1" src="cid:173307c9016a1e1f5a21"></p>
<div id="gmail-m_7603816165024406521gmail-m_4618596293159926224divRplyFwdMsg">
<p class="MsoNormal"><b><span style="color:black">From:</span></b><span style="color:black"> Devarajan, Hariharan <<a href="mailto:hdevarajan@anl.gov" target="_blank">hdevarajan@anl.gov</a>><br>
<b>Sent:</b> Wednesday, July 8, 2020 9:45 AM<br>
<b>To:</b> Snyder, Shane <<a href="mailto:ssnyder@mcs.anl.gov" target="_blank">ssnyder@mcs.anl.gov</a>><br>
<b>Cc:</b> Jeffrey Layton <<a href="mailto:laytonjb@gmail.com" target="_blank">laytonjb@gmail.com</a>>;
<a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">darshan-users@lists.mcs.anl.gov</a> <<a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">darshan-users@lists.mcs.anl.gov</a>><br>
<b>Subject:</b> Re: [Darshan-users] Darshan not tracing with tensorflow import.</span>
</p>
<div>
<p class="MsoNormal"> </p>
</div>
</div>
<div>
<p class="MsoNormal">It produces logs but it stops tracing h5py and np.load calls. If u run the working version, u will notice we get traces from both files but when u add import of tensorflow, this
stops. I have verified that darshan is initializing as we get logs just not giving tracing for those two files in the code.
</p>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">Hari</p>
<div>
<p class="MsoNormal" style="margin-bottom:12pt"><u></u> <u></u></p>
<blockquote style="margin-top:5pt;margin-bottom:5pt">
<p class="MsoNormal" style="margin-bottom:12pt">On Jul 8, 2020, at 9:41 AM, Snyder, Shane <<a href="mailto:ssnyder@mcs.anl.gov" target="_blank">ssnyder@mcs.anl.gov</a>> wrote:</p>
</blockquote>
</div>
<blockquote style="margin-top:5pt;margin-bottom:5pt">
<div>
<p class="MsoNormal">
</p>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">Hi
</span><span style="font-size:12pt;color:rgb(33,33,33)">Hariharan</span><span style="font-size:12pt;color:black">,</span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"> </span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">Thanks for letting us know about this issue.</span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"> </span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">I can't really think of any reason why the import of tensorflow module would result in Darshan no longer producing log files. Just to
make sure I'm fully understanding, you aren't getting any logfiles at all in the case where tensorflow is imported? I ask because when using this non-MPI instrumentation, I've noticed it tends to create a lot of log files, particularly for Python modules that
like to call subprocesses for using things like ls, sed, etc. I just want to make sure it's not an issue of you missing one particular log file of interest or whether you don't get any log files at all.</span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"> </span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">At any rate, the environment setup looks correct in both cases to preload the Darshan library and to enable the non-MPI instrumentation
support. So, that doesn't appear to be the issue.</span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"> </span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">Just to verify whether Darshan is even being properly initialized/shutdown, could you try setting the DARSHAN_INTERNAL_TIMING env variable
(i.e., export </span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">DARSHAN_INTERNAL_TIMING=1) before running? That should spit out some more verbose output about how long it takes Darshan to init/finalize.
If you do see some additional output indicating Darshan is at least initializing, you might want to double check that there are no errors in your output logs that indicate some issue Darshan encountered.</span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"> </span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">--Shane</span></p>
</div>
<p class="MsoNormal"><img border="0" width="462" height="2" style="width: 4.8083in; height: 0.025in;" id="gmail-m_7603816165024406521gmail-m_4618596293159926224Horizontal_x0020_Line_x0020_2" src="cid:173307c901723f2a2472"></p>
<div id="gmail-m_7603816165024406521gmail-m_4618596293159926224x_divRplyFwdMsg">
<p class="MsoNormal"><b><span style="color:black">From:</span></b><span style="color:black"> Darshan-users <<a href="mailto:darshan-users-bounces@lists.mcs.anl.gov" target="_blank">darshan-users-bounces@lists.mcs.anl.gov</a>>
on behalf of Devarajan, Hariharan <<a href="mailto:hdevarajan@anl.gov" target="_blank">hdevarajan@anl.gov</a>><br>
<b>Sent:</b> Monday, July 6, 2020 9:56 AM<br>
<b>To:</b> Jeffrey Layton <<a href="mailto:laytonjb@gmail.com" target="_blank">laytonjb@gmail.com</a>><br>
<b>Cc:</b> <a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">darshan-users@lists.mcs.anl.gov</a> <<a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">darshan-users@lists.mcs.anl.gov</a>><br>
<b>Subject:</b> Re: [Darshan-users] Darshan not tracing with tensorflow import.</span>
</p>
<div>
<p class="MsoNormal"> </p>
</div>
</div>
<div>
<div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal">The I/O is not through tensorflow. Its through h5py and numpy.load and I verified both without tensorflow import are getting traced. I already verified that import of tensorflow doesn’t change any environment
variables. </p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"> </p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal">Hari</p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"> </p>
<div style="border-right:none;border-bottom:none;border-left:none;border-top:1pt solid rgb(225,225,225);padding:3pt 0in 0in">
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"><b>From: </b><a href="mailto:laytonjb@gmail.com" target="_blank">Jeffrey Layton</a><br>
<b>Sent: </b>Monday, July 6, 2020 9:41 AM<br>
<b>To: </b><a href="mailto:hdevarajan@anl.gov" target="_blank">Devarajan, Hariharan</a><br>
<b>Cc: </b><a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">darshan-users@lists.mcs.anl.gov</a><br>
<b>Subject: </b>Re: [Darshan-users] Darshan not tracing with tensorflow import.</p>
</div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"> </p>
<div>
<div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal">About 2 months ago, I tried using Darshan to trace a TensorFlow2 DL training. I could not trace the input. What I _think_ happens is the TF2 uses mmap() for reading the input files and I don't think Darshan can
capture that file IO. But I'm not a Darshan expert so perhaps someone has tried this before and can help</p>
</div>
<div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"> </p>
</div>
<div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal">(BTW - it's possible to build TensorFlow so it doesn't use mmap() for reading files.)</p>
</div>
<div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"> </p>
</div>
<div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal">Jeff</p>
</div>
<div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"> </p>
</div>
<div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"> </p>
</div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"> </p>
<div>
<div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal">On Mon, Jul 6, 2020 at 1:08 PM Devarajan, Hariharan <<a href="mailto:hdevarajan@anl.gov" target="_blank">hdevarajan@anl.gov</a>> wrote:</p>
</div>
<blockquote style="border-top:none;border-right:none;border-bottom:none;border-left:1pt solid rgb(204,204,204);padding:0in 0in 0in 6pt;margin:5pt 0in 5pt 4.8pt">
<div>
<div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"> </p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal" style="background:white"><span style="color:rgb(33,33,33)">Hello,</span></p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal" style="background:white"><span style="color:rgb(33,33,33)"> </span></p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal" style="background:white"><span style="color:rgb(33,33,33)">I was able to run my test program with 3.2.1 darshan. However, when i trace an app which load tensorflow it seems darshan doesn't produce trace. I am attaching
two tars one with working example and one without. The only difference between the two is in test.py where i import tensorflow on first line.</span></p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal" style="background:white"><span style="color:rgb(33,33,33)"> </span></p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal" style="background:white"><span style="color:rgb(33,33,33)">Can you please assist on how I can further debug the problem?
</span></p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal" style="background:white"><span style="color:rgb(33,33,33)"> </span></p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal" style="background:white"><span style="color:rgb(33,33,33)">Regards</span></p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal" style="background:white"><span style="color:rgb(33,33,33)">Hariharan</span></p>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal"> </p>
</div>
</div>
</blockquote>
</div>
</div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal" style="margin-left:4.8pt">_______________________________________________<br>
Darshan-users mailing list<br>
<a href="mailto:Darshan-users@lists.mcs.anl.gov" target="_blank">Darshan-users@lists.mcs.anl.gov</a><br>
<a href="https://lists.mcs.anl.gov/mailman/listinfo/darshan-users" target="_blank">https://lists.mcs.anl.gov/mailman/listinfo/darshan-users</a></p>
</div>
</div>
</div>
</blockquote>
</div>
</div>
<p class="gmail-m_7603816165024406521gmail-m4618596293159926224xxmsonormal" style="margin-right:0.5in;margin-bottom:5pt;margin-left:0.5in">
</p>
<p class="MsoNormal"> </p>
</div>
</div>
</blockquote>
</div>
<p class="MsoNormal" style="margin-left:4.8pt">_______________________________________________<br>
Darshan-users mailing list<br>
<a href="mailto:Darshan-users@lists.mcs.anl.gov" target="_blank">Darshan-users@lists.mcs.anl.gov</a><br>
<a href="https://lists.mcs.anl.gov/mailman/listinfo/darshan-users" target="_blank">https://lists.mcs.anl.gov/mailman/listinfo/darshan-users</a><u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
</div>
</blockquote></div>