Conversation
Run file for com6RockAvalanche Scarp
Config-File for scarp.py
Scarp.py creates scarps, that can be used as an Input for com6RockAvalanche
- Refactored `runCom6Scarp.py` to accept an input directory instead of a configuration file path. - Added TODO comments for further improvements in `scarp.py`, `scarpCfg.ini`, and `runCom6Scarp.py` regarding default parameter handling and output file management.
- Implement shapefile input for feature coordinates and perimeter. - Remove raster input options for coordinates and perimeter. - Adapt `scarp.py` to use new input method and updated config. - Adjust `runCom6Scarp.py` to use refactored `scarp.py` functions. - Remove obsolete output paths from config file.
Run file for com6RockAvalanche Scarp
Config-File for scarp.py
Scarp.py creates scarps, that can be used as an Input for com6RockAvalanche
- Refactored `runCom6Scarp.py` to accept an input directory instead of a configuration file path. - Added TODO comments for further improvements in `scarp.py`, `scarpCfg.ini`, and `runCom6Scarp.py` regarding default parameter handling and output file management.
- Implement shapefile input for feature coordinates and perimeter. - Remove raster input options for coordinates and perimeter. - Adapt `scarp.py` to use new input method and updated config. - Adjust `runCom6Scarp.py` to use refactored `scarp.py` functions. - Remove obsolete output paths from config file.
- Implement shapefile input for feature coordinates and perimeter. - Adapt Readme - commit includes test data in data/scarpExample
- Run file for com6RockAvalanche Scarp - Create scarpCfg.ini - Config-File for scarp.py - Create scarp.py - scarp.py creates scarps, that can be used as an Input for com6RockAvalanche - com6RockAvalanche: update scarp.py, runCom6Scarp.py & scarpCfg.ini, add readme
- Refactored `runCom6Scarp.py` to accept an input directory instead of a configuration file path. - Added TODO comments for further improvements in `scarp.py`, `scarpCfg.ini`, and `runCom6Scarp.py` regarding default parameter handling and output file management. feat(com6RockAvalanche): implement shapefile input for scarp - Implement shapefile input for feature coordinates and perimeter. - Remove raster input options for coordinates and perimeter. - Adapt `scarp.py` to use new input method and updated config. - Adjust `runCom6Scarp.py` to use refactored `scarp.py` functions. - Remove obsolete output paths from config file.
…fo; remove codeclimate - Add instructions for input files, including elevation DEM and shapefile - Specify output files and their locations in the directory structure - Include steps for preparing the configuration file for scarp calculations - Clarify the usage of the script for running SCARP calculations
Updates the ellipsoid function of the scarp script.
Comment on lines
+324
to
+338
| if 0 <= center_row < n and 0 <= center_col < m: | ||
| slopeAzimuth = slopeDir[center_row, center_col] | ||
| slopeAzimuth = (slopeAzimuth + 2 * np.pi) % (2 * np.pi) | ||
| slopeMag = slopeMagnitude[center_row, center_col] | ||
|
|
||
| if not np.isnan(slopeAzimuth) and slopeMag > 0: | ||
| normal_dx = np.cos(slopeAzimuth) | ||
| normal_dy = np.sin(slopeAzimuth) | ||
| slopeAngle = math.atan(slopeMag) | ||
| dxOffset = -offset[k] * normal_dx * math.sin(slopeAngle) | ||
| dyOffset = -offset[k] * normal_dy * math.sin(slopeAngle) | ||
| dzOffset = -offset[k] * math.cos(slopeAngle) | ||
| else: | ||
| dxOffset = dyOffset = dzOffset = 0 | ||
| else: |
Contributor
Comment on lines
+357
to
+362
| if distance <= 1: | ||
| baseDepth = maxDepth[k] * (1 - distance) | ||
| tiltEffect = math.tan(math.radians(tilt[k])) * ( | ||
| dxRot * np.cos(tiltDir[k]) + dyRot * np.sin(tiltDir[k]) | ||
| ) | ||
| totalDepth = baseDepth + tiltEffect + z0 |
Contributor
| maxdepth_value = value | ||
| if name == "semimajor": | ||
| semimajor_value = value | ||
| if name == "tilt": |
Contributor
| semimajor_value = value | ||
| if name == "tilt": | ||
| tilt_value = value | ||
| if name == "direc": |
Contributor
| tilt_value = value | ||
| if name == "direc": | ||
| direc_value = value | ||
| if name == "offset": |
Contributor
Contributor
|
closing in favor of #1172 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Updates the ellipsoid method of the scarp script, so that users can now define more specific ellispoids