Commit 9ec2fce9 authored by Cristian Lalescu's avatar Cristian Lalescu
Browse files

add basic descriptions for classes

parent a9eaabaf
......@@ -30,6 +30,11 @@ import os
from ._fluid_base import _fluid_particle_base
class FluidConvert(_fluid_particle_base):
"""This class is meant to be used for conversion of native DNS field
representations to real-space representations of velocity/vorticity
fields.
It may be superseeded by streamlined functionality in the future...
"""
def __init__(
self,
name = 'FluidConvert',
......
......@@ -29,6 +29,10 @@ from ._fluid_base import _fluid_particle_base
import numpy as np
class FluidResize(_fluid_particle_base):
"""This class is meant to resize snapshots of DNS states to new grids.
Typical stuff for DNS of turbulence.
It will become superfluous when HDF5 is used for field I/O.
"""
def __init__(
self,
name = 'FluidResize',
......
......@@ -34,6 +34,11 @@ from .FluidResize import FluidResize
from .FluidConvert import FluidConvert
class Launcher:
"""Objects of this class are used in the executable bfps script.
It should work with any children of
:class:`NavierStokes <NavierStokes.NavierStokes>`;
failure to do so should be reported as a bug.
"""
def __init__(
self,
base_class = NavierStokes):
......
......@@ -31,6 +31,11 @@ import h5py
from ._fluid_base import _fluid_particle_base
class NavierStokes(_fluid_particle_base):
"""Objects of this class can be used to generate production DNS codes.
Any functionality that users require should be available through this class,
in the sense that they can implement whatever they need by simply inheriting
this class.
"""
def __init__(
self,
name = 'NavierStokes',
......
......@@ -31,9 +31,8 @@ import h5py
from bfps import install_info
class _base(object):
"""
This class contains simulation parameters, and handles parameter related
functionalities of both python objects and C++ codes.
"""This class contains simulation parameters, and handles parameter related
functionalities of both python objects and C++ codes.
"""
def __init__(
self,
......
......@@ -36,9 +36,8 @@ import bfps
from ._base import _base
class _code(_base):
"""
This class is meant to stitch together the C++ code into a final source file,
compile it, and handle all job launching.
"""This class is meant to stitch together the C++ code into a final source file,
compile it, and handle all job launching.
"""
def __init__(
self,
......
......@@ -32,6 +32,10 @@ import numpy as np
import h5py
class _fluid_particle_base(_code):
"""This class is meant to put together all common code between the
different C++ solvers/postprocessing tools, so that development of
specific functionalities is not overwhelming.
"""
def __init__(
self,
name = 'solver',
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment