1
$\begingroup$

I like to set my scientific simulation programs to generate a picture after a certain number of iterations, such that I can follow what is happening and maybe cancel the simulation before the initially planned iteration. The periodicity of the pictures must be such that they don't affect performance too much. Sometimes, I even create windows to enter the simulations' parameters.

I have already combined

  • Fortran with C with OpenGL (the Fortran program generated a C/OpenGL code and executed it)
  • Java with Java 2D or Java 3D with GUI created with Swing (NetBeans)

Java has the advantage of portability, but I don't know how slower than Fortran and C it is, because I wrote different programs with each of them.

Do you use another solution for real-time image printing or visualization between N [preferably high-performance] iterations?

$\endgroup$
1
  • $\begingroup$ What about using Paraview InSitu? The idea of it is to do what you just described $\endgroup$
    – nicoguaro
    Commented Dec 8, 2015 at 21:52

1 Answer 1

3
$\begingroup$

My typical approach to this is to produce output data files that contain data at the required intervals and to visualize them in a batch way with a separate tool (Paraview, VisIt, Tecplot, MATLAB, etc.) at my leisure. With a fast filesystem and good parallel I/O package (HDF5, MPI I/O, ADIOS, etc.), this can often be done without disturbing the performance of your solution process too much.

Do you have evidence that producing the picture within your program is currently a bottleneck? I.e., do you have timings or profiling data that shows this? It's not usual that producing output is a bottleneck, but it can be if you are producing it too frequently.

$\endgroup$
2
  • $\begingroup$ Actually, I don't have that evidence, except for the Fortran-C-OpenGL program that printed images onscreen too frequently, causing computer crash sometimes. $\endgroup$ Commented Dec 12, 2015 at 11:14
  • $\begingroup$ That really makes it sound like to me that you should be writing these results to disk and reading them back in for visualization purposes, that or lengthen the time you plot them substantially. $\endgroup$
    – Bill Barth
    Commented Dec 12, 2015 at 14:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.