Re: [petsc-dev] getting on with the nested timers

2018-04-09 Thread Smith, Barry F.

   Hopefully all these problems are resolved with 
https://bitbucket.org/petsc/petsc/pull-requests/925/fix-some-missing-functionality-for-nested/diff

  Barry


> On Apr 5, 2018, at 6:31 AM, Klaij, Christiaan <c.kl...@marin.nl> wrote:
> 
> Matt,
> 
> I guess you meant to send this link:
> 
> http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Viewer/PetscViewerPushFormat.html
> 
> If so, it doesn't say anything on XML either. But after some
> trial and error I found the format to
> be "PETSC_VIEWER_ASCII_XML", so problem solved.
> 
> Summarizing the problem from a user perspective:
> 
> 1) The manual page of PetscLogView mentions PetscViewerASCIIOpen,
> which mentions PetscViewerPushFormat, I should have figured that
> out by myself, sorry.
> 
> 2) The manual page of PetscLogView mentions PetscLogNestedBegin,
> which doesn't have a manual entry.
> 
> 3) The manual page of PetscViewerPushFormat doesn't mention the
> format PETSC_VIEWER_ASCII_XML, although it is available.
> 
> Chris
> 
> dr. ir. Christiaan Klaij | Senior Researcher | Research & Development
> MARIN | T +31 317 49 33 44 | c.kl...@marin.nl | www.marin.nl
> 
>
> MARIN news: Comfort draft for semi-submersible yachts
> From: Matthew Knepley <knep...@gmail.com>
> Sent: Thursday, April 05, 2018 12:50 PM
> To: Klaij, Christiaan
> Cc: Smith, Barry F.; petsc-dev@mcs.anl.gov; Koos Huijssen
> Subject: Re: [petsc-dev] getting on with the nested timers
>  
> On Thu, Apr 5, 2018 at 6:15 AM, Klaij, Christiaan <c.kl...@marin.nl> wrote:
> Barry,
> 
> I'm still trying to use petsc's nested logging with our code. I
> have it working for 3.8.3 with the command line option, for
> example:
> 
> mpirun -n 3 ./refresco -log_view :performance.xml:ascii_xml
> 
> This gives the expected performance.xml file. How to get the same
> without command line options? So far I have:
> 
> CALL PetscLogDefaultBegin(ierr)
> ...
> CALL PetscViewerASCIIOpen(MPI_COMM_WORLD,'performance.xml',viewer,ierr)
> CALL PetscLogView(viewer,ierr)
> 
> which gives the regular log in the performance.xml file.
> 
> I guess I should replace PetscLogDefaultBegin by
> PetscLogNestedBegin as stated in the manual page of PetscLogView.
> 
> But there's no manual page for PetscLogNestedBegin and I didn't
> find anything like PetscViewerASCIIOpenXML either.
> 
> http://www.mcs.anl.gov/petsc/petsc-master/docs/manualpages/Profiling/PetscLogView.html
> 
> You need to push the ASCII_XML format before viewing.
> 
>   Thanks,
> 
>  Matt
>  
> Chris
> 
> 
> dr. ir. Christiaan Klaij  | Senior Researcher | Research & Development
> MARIN | T +31 317 49 33 44 | mailto:c.kl...@marin.nl | http://www.marin.nl
> 
> MARIN news: 
> http://www.marin.nl/web/News/News-items/Kom-zaterdag-10-november-naar-de-open-dag-in-Wageningen.htm
> 
> 
> 
> 
> -- 
> What most experimenters take for granted before they begin their experiments 
> is infinitely more interesting than any results to which their experiments 
> lead.
> -- Norbert Wiener
> 
> https://www.cse.buffalo.edu/~knepley/



Re: [petsc-dev] getting on with the nested timers

2018-04-05 Thread Matthew Knepley
On Thu, Apr 5, 2018 at 7:50 AM, Klaij, Christiaan <c.kl...@marin.nl> wrote:

> ??? In my original email I mention that page and state that the
> command line option is working.
>
>
> Were you expecting me to understand from your reply that the
> option :ascii_xml somehow translates to
> PetscViewerPushFormat(viewer,"PETSC_VIEWER_ASCII_XML")?
>
Yes. The format for viewer input is

  -foo_view type:filename:format:mode

where any argument can be omitted so that it takes the default. The
defaults are

  type- ascii
  filename - stdout
  format- FORMAT_DEFAULT
  mode - read

  Thanks,

  Matt

> Chris
> --
> *From:* Matthew Knepley <knep...@gmail.com>
> *Sent:* Thursday, April 05, 2018 1:35 PM
> *To:* Klaij, Christiaan
> *Cc:* Smith, Barry F.; petsc-dev@mcs.anl.gov; Koos Huijssen
> *Subject:* Re: [petsc-dev] getting on with the nested timers
>
> On Thu, Apr 5, 2018 at 7:31 AM, Klaij, Christiaan <c.kl...@marin.nl>
> wrote:
>
>> Matt,
>>
>> I guess you meant to send this link:
>>
>> http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/
>> Viewer/PetscViewerPushFormat.html
>>
> No, I meant to send the link I sent. In the section Options Database Keys,
> it gives you the format.
>
>   Matt
>
>>
>> If so, it doesn't say anything on XML either. But after some
>> trial and error I found the format to
>> be "PETSC_VIEWER_ASCII_XML", so problem solved.
>>
>> Summarizing the problem from a user perspective:
>>
>> 1) The manual page of PetscLogView mentions PetscViewerASCIIOpen,
>> which mentions PetscViewerPushFormat, I should have figured that
>> out by myself, sorry.
>>
>> 2) The manual page of PetscLogView mentions PetscLogNestedBegin,
>> which doesn't have a manual entry.
>>
>> 3) The manual page of PetscViewerPushFormat doesn't mention the
>> format PETSC_VIEWER_ASCII_XML, although it is available.
>>
>> Chris
>>
>> dr. ir. Christiaan Klaij | Senior Researcher | Research & Development
>> MARIN | T +31 317 49 33 44 | c.kl...@marin.nl | www.marin.nl
>>
>> [image: LinkedIn] <https://www.linkedin.com/company/marin> [image:
>> YouTube] <http://www.youtube.com/marinmultimedia> [image: Twitter]
>> <https://twitter.com/MARIN_nieuws> [image: Facebook]
>> <https://www.facebook.com/marin.wageningen>
>> MARIN news: Comfort draft for semi-submersible yachts
>> <http://www.marin.nl/web/News/News-items/Comfort-draft-for-semisubmersible-yachts.htm>
>>
>> --
>> *From:* Matthew Knepley <knep...@gmail.com>
>> *Sent:* Thursday, April 05, 2018 12:50 PM
>> *To:* Klaij, Christiaan
>> *Cc:* Smith, Barry F.; petsc-dev@mcs.anl.gov; Koos Huijssen
>> *Subject:* Re: [petsc-dev] getting on with the nested timers
>>
>> On Thu, Apr 5, 2018 at 6:15 AM, Klaij, Christiaan <c.kl...@marin.nl>
>> wrote:
>>
>>> Barry,
>>>
>>> I'm still trying to use petsc's nested logging with our code. I
>>> have it working for 3.8.3 with the command line option, for
>>> example:
>>>
>>> mpirun -n 3 ./refresco -log_view :performance.xml:ascii_xml
>>>
>>> This gives the expected performance.xml file. How to get the same
>>> without command line options? So far I have:
>>>
>>> CALL PetscLogDefaultBegin(ierr)
>>> ...
>>> CALL PetscViewerASCIIOpen(MPI_COMM_WORLD,'performance.xml',viewer,ierr)
>>> CALL PetscLogView(viewer,ierr)
>>>
>>> which gives the regular log in the performance.xml file.
>>>
>>> I guess I should replace PetscLogDefaultBegin by
>>> PetscLogNestedBegin as stated in the manual page of PetscLogView.
>>>
>>> But there's no manual page for PetscLogNestedBegin and I didn't
>>> find anything like PetscViewerASCIIOpenXML either.
>>>
>>
>> http://www.mcs.anl.gov/petsc/petsc-master/docs/manualpages/P
>> rofiling/PetscLogView.html
>>
>> You need to push the ASCII_XML format before viewing.
>>
>>   Thanks,
>>
>>  Matt
>>
>>
>>> Chris
>>>
>>>
>>> dr. ir. Christiaan Klaij  | Senior Researcher | Research & Development
>>> MARIN | T +31 317 49 33 44 | mailto:c.kl...@marin.nl |
>>> http://www.marin.nl
>>>
>>> MARIN news: http://www.marin.nl/web/News/News-items/Kom-zaterdag-10-nove
>>> mber-naar-de-open-dag-in-Wageningen.htm
>>>
>>>
>>
>>
>> --
>> What most experimenters take for granted before they begin their
>> experiments is infinitely more interesting than any results to which their
>> experiments lead.
>> -- Norbert Wiener
>>
>> https://www.cse.buffalo.edu/~knepley/ <http://www.caam.rice.edu/~mk51/>
>>
>>
>
>
> --
> What most experimenters take for granted before they begin their
> experiments is infinitely more interesting than any results to which their
> experiments lead.
> -- Norbert Wiener
>
> https://www.cse.buffalo.edu/~knepley/ <http://www.caam.rice.edu/~mk51/>
>



-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/ <http://www.caam.rice.edu/~mk51/>


Re: [petsc-dev] getting on with the nested timers

2018-04-05 Thread Klaij, Christiaan
??? In my original email I mention that page and state that the
command line option is working.


Were you expecting me to understand from your reply that the
option :ascii_xml somehow translates to
PetscViewerPushFormat(viewer,"PETSC_VIEWER_ASCII_XML")?


Chris


From: Matthew Knepley <knep...@gmail.com>
Sent: Thursday, April 05, 2018 1:35 PM
To: Klaij, Christiaan
Cc: Smith, Barry F.; petsc-dev@mcs.anl.gov; Koos Huijssen
Subject: Re: [petsc-dev] getting on with the nested timers

On Thu, Apr 5, 2018 at 7:31 AM, Klaij, Christiaan 
<c.kl...@marin.nl<mailto:c.kl...@marin.nl>> wrote:

Matt,

I guess you meant to send this link:

http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Viewer/PetscViewerPushFormat.html

No, I meant to send the link I sent. In the section Options Database Keys, it 
gives you the format.

  Matt

If so, it doesn't say anything on XML either. But after some
trial and error I found the format to
be "PETSC_VIEWER_ASCII_XML", so problem solved.

Summarizing the problem from a user perspective:

1) The manual page of PetscLogView mentions PetscViewerASCIIOpen,
which mentions PetscViewerPushFormat, I should have figured that
out by myself, sorry.

2) The manual page of PetscLogView mentions PetscLogNestedBegin,
which doesn't have a manual entry.

3) The manual page of PetscViewerPushFormat doesn't mention the
format PETSC_VIEWER_ASCII_XML, although it is available.

Chris

dr. ir. Christiaan Klaij | Senior Researcher | Research & Development
MARIN | T +31 317 49 33 44 | c.kl...@marin.nl<mailto:c.kl...@marin.nl> | 
www.marin.nl<http://www.marin.nl>

[LinkedIn]<https://www.linkedin.com/company/marin> [YouTube] 
<http://www.youtube.com/marinmultimedia>  [Twitter] 
<https://twitter.com/MARIN_nieuws>  [Facebook] 
<https://www.facebook.com/marin.wageningen>
MARIN news: Comfort draft for semi-submersible 
yachts<http://www.marin.nl/web/News/News-items/Comfort-draft-for-semisubmersible-yachts.htm>


From: Matthew Knepley <knep...@gmail.com<mailto:knep...@gmail.com>>
Sent: Thursday, April 05, 2018 12:50 PM
To: Klaij, Christiaan
Cc: Smith, Barry F.; petsc-dev@mcs.anl.gov<mailto:petsc-dev@mcs.anl.gov>; Koos 
Huijssen
Subject: Re: [petsc-dev] getting on with the nested timers

On Thu, Apr 5, 2018 at 6:15 AM, Klaij, Christiaan 
<c.kl...@marin.nl<mailto:c.kl...@marin.nl>> wrote:
Barry,

I'm still trying to use petsc's nested logging with our code. I
have it working for 3.8.3 with the command line option, for
example:

mpirun -n 3 ./refresco -log_view :performance.xml:ascii_xml

This gives the expected performance.xml file. How to get the same
without command line options? So far I have:

CALL PetscLogDefaultBegin(ierr)
...
CALL PetscViewerASCIIOpen(MPI_COMM_WORLD,'performance.xml',viewer,ierr)
CALL PetscLogView(viewer,ierr)

which gives the regular log in the performance.xml file.

I guess I should replace PetscLogDefaultBegin by
PetscLogNestedBegin as stated in the manual page of PetscLogView.

But there's no manual page for PetscLogNestedBegin and I didn't
find anything like PetscViewerASCIIOpenXML either.

http://www.mcs.anl.gov/petsc/petsc-master/docs/manualpages/Profiling/PetscLogView.html

You need to push the ASCII_XML format before viewing.

  Thanks,

 Matt

Chris


dr. ir. Christiaan Klaij  | Senior Researcher | Research & Development
MARIN | T +31 317 49 33 44 | mailto:c.kl...@marin.nl<mailto:c.kl...@marin.nl> | 
http://www.marin.nl

MARIN news: 
http://www.marin.nl/web/News/News-items/Kom-zaterdag-10-november-naar-de-open-dag-in-Wageningen.htm




--
What most experimenters take for granted before they begin their experiments is 
infinitely more interesting than any results to which their experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/<http://www.caam.rice.edu/~mk51/>



--
What most experimenters take for granted before they begin their experiments is 
infinitely more interesting than any results to which their experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/<http://www.caam.rice.edu/~mk51/>


Re: [petsc-dev] getting on with the nested timers

2018-04-05 Thread Matthew Knepley
On Thu, Apr 5, 2018 at 7:31 AM, Klaij, Christiaan <c.kl...@marin.nl> wrote:

> Matt,
>
> I guess you meant to send this link:
>
> http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Viewer/
> PetscViewerPushFormat.html
>
No, I meant to send the link I sent. In the section Options Database Keys,
it gives you the format.

  Matt

>
> If so, it doesn't say anything on XML either. But after some
> trial and error I found the format to
> be "PETSC_VIEWER_ASCII_XML", so problem solved.
>
> Summarizing the problem from a user perspective:
>
> 1) The manual page of PetscLogView mentions PetscViewerASCIIOpen,
> which mentions PetscViewerPushFormat, I should have figured that
> out by myself, sorry.
>
> 2) The manual page of PetscLogView mentions PetscLogNestedBegin,
> which doesn't have a manual entry.
>
> 3) The manual page of PetscViewerPushFormat doesn't mention the
> format PETSC_VIEWER_ASCII_XML, although it is available.
>
> Chris
>
> dr. ir. Christiaan Klaij | Senior Researcher | Research & Development
> MARIN | T +31 317 49 33 44 | c.kl...@marin.nl | www.marin.nl
>
> [image: LinkedIn] <https://www.linkedin.com/company/marin> [image:
> YouTube] <http://www.youtube.com/marinmultimedia> [image: Twitter]
> <https://twitter.com/MARIN_nieuws> [image: Facebook]
> <https://www.facebook.com/marin.wageningen>
> MARIN news: Comfort draft for semi-submersible yachts
> <http://www.marin.nl/web/News/News-items/Comfort-draft-for-semisubmersible-yachts.htm>
>
> --
> *From:* Matthew Knepley <knep...@gmail.com>
> *Sent:* Thursday, April 05, 2018 12:50 PM
> *To:* Klaij, Christiaan
> *Cc:* Smith, Barry F.; petsc-dev@mcs.anl.gov; Koos Huijssen
> *Subject:* Re: [petsc-dev] getting on with the nested timers
>
> On Thu, Apr 5, 2018 at 6:15 AM, Klaij, Christiaan <c.kl...@marin.nl>
> wrote:
>
>> Barry,
>>
>> I'm still trying to use petsc's nested logging with our code. I
>> have it working for 3.8.3 with the command line option, for
>> example:
>>
>> mpirun -n 3 ./refresco -log_view :performance.xml:ascii_xml
>>
>> This gives the expected performance.xml file. How to get the same
>> without command line options? So far I have:
>>
>> CALL PetscLogDefaultBegin(ierr)
>> ...
>> CALL PetscViewerASCIIOpen(MPI_COMM_WORLD,'performance.xml',viewer,ierr)
>> CALL PetscLogView(viewer,ierr)
>>
>> which gives the regular log in the performance.xml file.
>>
>> I guess I should replace PetscLogDefaultBegin by
>> PetscLogNestedBegin as stated in the manual page of PetscLogView.
>>
>> But there's no manual page for PetscLogNestedBegin and I didn't
>> find anything like PetscViewerASCIIOpenXML either.
>>
>
> http://www.mcs.anl.gov/petsc/petsc-master/docs/manualpages/
> Profiling/PetscLogView.html
>
> You need to push the ASCII_XML format before viewing.
>
>   Thanks,
>
>  Matt
>
>
>> Chris
>>
>>
>> dr. ir. Christiaan Klaij  | Senior Researcher | Research & Development
>> MARIN | T +31 317 49 33 44 | mailto:c.kl...@marin.nl |
>> http://www.marin.nl
>>
>> MARIN news: http://www.marin.nl/web/News/News-items/Kom-zaterdag-10-nove
>> mber-naar-de-open-dag-in-Wageningen.htm
>>
>>
>
>
> --
> What most experimenters take for granted before they begin their
> experiments is infinitely more interesting than any results to which their
> experiments lead.
> -- Norbert Wiener
>
> https://www.cse.buffalo.edu/~knepley/ <http://www.caam.rice.edu/~mk51/>
>
>


-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/ <http://www.caam.rice.edu/~mk51/>


Re: [petsc-dev] getting on with the nested timers

2018-04-05 Thread Klaij, Christiaan
Matt,

I guess you meant to send this link:

http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Viewer/PetscViewerPushFormat.html

If so, it doesn't say anything on XML either. But after some
trial and error I found the format to
be "PETSC_VIEWER_ASCII_XML", so problem solved.

Summarizing the problem from a user perspective:

1) The manual page of PetscLogView mentions PetscViewerASCIIOpen,
which mentions PetscViewerPushFormat, I should have figured that
out by myself, sorry.

2) The manual page of PetscLogView mentions PetscLogNestedBegin,
which doesn't have a manual entry.

3) The manual page of PetscViewerPushFormat doesn't mention the
format PETSC_VIEWER_ASCII_XML, although it is available.

Chris

dr. ir. Christiaan Klaij | Senior Researcher | Research & Development
MARIN | T +31 317 49 33 44 | c.kl...@marin.nl<mailto:c.kl...@marin.nl> | 
www.marin.nl<http://www.marin.nl>

[LinkedIn]<https://www.linkedin.com/company/marin> [YouTube] 
<http://www.youtube.com/marinmultimedia>  [Twitter] 
<https://twitter.com/MARIN_nieuws>  [Facebook] 
<https://www.facebook.com/marin.wageningen>
MARIN news: Comfort draft for semi-submersible 
yachts<http://www.marin.nl/web/News/News-items/Comfort-draft-for-semisubmersible-yachts.htm>


From: Matthew Knepley <knep...@gmail.com>
Sent: Thursday, April 05, 2018 12:50 PM
To: Klaij, Christiaan
Cc: Smith, Barry F.; petsc-dev@mcs.anl.gov; Koos Huijssen
Subject: Re: [petsc-dev] getting on with the nested timers

On Thu, Apr 5, 2018 at 6:15 AM, Klaij, Christiaan 
<c.kl...@marin.nl<mailto:c.kl...@marin.nl>> wrote:
Barry,

I'm still trying to use petsc's nested logging with our code. I
have it working for 3.8.3 with the command line option, for
example:

mpirun -n 3 ./refresco -log_view :performance.xml:ascii_xml

This gives the expected performance.xml file. How to get the same
without command line options? So far I have:

CALL PetscLogDefaultBegin(ierr)
...
CALL PetscViewerASCIIOpen(MPI_COMM_WORLD,'performance.xml',viewer,ierr)
CALL PetscLogView(viewer,ierr)

which gives the regular log in the performance.xml file.

I guess I should replace PetscLogDefaultBegin by
PetscLogNestedBegin as stated in the manual page of PetscLogView.

But there's no manual page for PetscLogNestedBegin and I didn't
find anything like PetscViewerASCIIOpenXML either.

http://www.mcs.anl.gov/petsc/petsc-master/docs/manualpages/Profiling/PetscLogView.html

You need to push the ASCII_XML format before viewing.

  Thanks,

 Matt

Chris


dr. ir. Christiaan Klaij  | Senior Researcher | Research & Development
MARIN | T +31 317 49 33 44 | mailto:c.kl...@marin.nl<mailto:c.kl...@marin.nl> | 
http://www.marin.nl

MARIN news: 
http://www.marin.nl/web/News/News-items/Kom-zaterdag-10-november-naar-de-open-dag-in-Wageningen.htm




--
What most experimenters take for granted before they begin their experiments is 
infinitely more interesting than any results to which their experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/<http://www.caam.rice.edu/~mk51/>




Re: [petsc-dev] getting on with the nested timers

2018-04-05 Thread Matthew Knepley
On Thu, Apr 5, 2018 at 6:15 AM, Klaij, Christiaan  wrote:

> Barry,
>
> I'm still trying to use petsc's nested logging with our code. I
> have it working for 3.8.3 with the command line option, for
> example:
>
> mpirun -n 3 ./refresco -log_view :performance.xml:ascii_xml
>
> This gives the expected performance.xml file. How to get the same
> without command line options? So far I have:
>
> CALL PetscLogDefaultBegin(ierr)
> ...
> CALL PetscViewerASCIIOpen(MPI_COMM_WORLD,'performance.xml',viewer,ierr)
> CALL PetscLogView(viewer,ierr)
>
> which gives the regular log in the performance.xml file.
>
> I guess I should replace PetscLogDefaultBegin by
> PetscLogNestedBegin as stated in the manual page of PetscLogView.
>
> But there's no manual page for PetscLogNestedBegin and I didn't
> find anything like PetscViewerASCIIOpenXML either.
>

http://www.mcs.anl.gov/petsc/petsc-master/docs/manualpages/Profiling/PetscLogView.html

You need to push the ASCII_XML format before viewing.

  Thanks,

 Matt


> Chris
>
>
> dr. ir. Christiaan Klaij  | Senior Researcher | Research & Development
> MARIN | T +31 317 49 33 44 | mailto:c.kl...@marin.nl | http://www.marin.nl
>
> MARIN news: http://www.marin.nl/web/News/News-items/Kom-zaterdag-10-
> november-naar-de-open-dag-in-Wageningen.htm
>
>


-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/