Skip to content

Commit

Permalink
Added docstring.
Browse files Browse the repository at this point in the history
  • Loading branch information
arkottke committed Jul 3, 2024
1 parent 976d882 commit b399927
Showing 1 changed file with 27 additions and 6 deletions.
33 changes: 27 additions & 6 deletions src/pystrata/variation.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
# SOFTWARE.
import copy
from abc import abstractmethod
from collections.abc import Generator

import numpy as np
import numpy.typing as npt
Expand Down Expand Up @@ -902,12 +903,32 @@ def std_mod_reduc(self):


def iter_varied_profiles(
profile,
count,
var_thickness: ToroThicknessVariation = None,
var_velocity: VelocityVariation = None,
var_soiltypes: SoilTypeVariation = None,
):
profile: site.Profile,
count: int,
var_thickness: ToroThicknessVariation | None = None,
var_velocity: VelocityVariation | None = None,
var_soiltypes: SoilTypeVariation | None = None,
) -> Generator[site.Profile]:
"""Iterate over simulated profiles
Parameters
----------
profile : site.Profile
seed profile
count : int
number of interations
var_thickness : ToroThicknessVariation | None
model for the thickness variation
var_velocity : VelocityVariation | None
model for the velocity variation
var_soiltypes : SoilTypeVariation | None
model for the soil type variation
Returns
-------
site.Profile
varied profile
"""
for _ in range(count):
# Copy the profile to form the realization
_profile = site.Profile.copy_of(profile)
Expand Down

0 comments on commit b399927

Please sign in to comment.