TerraFusion / basicFusion

Terra Basic Fusion Project - University of Illinois
Other
2 stars 0 forks source link

Documenting Code #237

Closed LandonTClipp closed 6 years ago

LandonTClipp commented 7 years ago

This will be a sort of "long-term" issue that we need to handle. Currently, there are many scripts and programs that are not documented properly. Mainly, code commenting needs to be a priority for us, especially since we will likely not be the only ones to use our code. Please modify all current and future code to comply with the following requirements:

  1. Comment everything very well. Make sure it is clear what you are attempting to achieve through the comments at every step in your code.
  2. Provide detailed function descriptions for all of the functions you make. Please refer to libTERRA.c and use the format shown there.
  3. Provide proper program descriptions that detail what the program does and how to use it. This is the format that must be used:
        [program name]

USAGE: [program name] [options]
DESCRIPTION:
        This program.... (note: Always start the description by describing exactly what the program does)
ARGUMENTS:
        -a            [Argument description]
        -b            [argument description]
etc.

This verbose description should be invoked when the program is run without any arguments. If your program does not take any arguments by default, then the verbose description should be invoked when using the -h flag.

Please follow this format as closely as possible.

LandonTClipp commented 7 years ago

@richielo @shashankbansal6

We will probably take an entire day every so often to clean up code and document properly. Proper code documentation is essential for any respectable project.

LandonTClipp commented 7 years ago

""" findJobPartition()

DESCRIPTION:
    This function determines which MPI jobs will be responsible for how many orbits. It loops through the
    list "orbits" and increments each element in the "processBin" list, up to len(orbits) number of orbits.

ARGUMENTS:
    numProcess (int)        -- The number of MPI processes (i.e. the number of bins to fill with orbits)
    orbits (list: int)      -- A list containing all of the Terra orbits that need to be processed.

EFFECTS:
    None

RETURN:
    Returns a list of size numProcess. Each element in the list tells how many orbits each MPI process will
    handle.
"""