Skip to content

Conversation

@PaulaSp3
Copy link
Contributor

@PaulaSp3 PaulaSp3 commented Nov 20, 2025

  • rasters are only merged if they are written as output.

  • computation time (for my example): +25%

  • new outputs:

    • mimimum volume of release area (raster)
    • maximum volume of release area (raster)
    • affected area for a segmented release area (that is marked by a release ID) (polygon)
    • Rel Id count (how many release areas - marked with a release ID) hit a cell (raster)
  • required input data (for these outputs):

    • the volume is given as raster value in release file (in REL folder)
    • the release ID is given as a raster (the release ID is the raster value). Cells with the same release ID belong the same release area. The raster is provided in Inputs/RELID.

still in progress

relVolMin and relVolMax as output

correct position for relId

delete print

small change

fix bug

pathPolygons as output

rename function

tidy up

try to keep RAM as small as possible

print a warning if the output in cfg is not completly valid

small corrections

correct bugs and doc

update docu
@PaulaSp3 PaulaSp3 self-assigned this Nov 20, 2025
@PaulaSp3 PaulaSp3 added enhancement New feature or request flowPyDev Ideas for future development labels Nov 20, 2025
@qltysh
Copy link
Contributor

qltysh bot commented Nov 20, 2025

8 new issues

Tool Category Rule Count
qlty Structure Deeply nested control flow (level = 4) 5
qlty Structure Function with many parameters (count = 16): __init__ 1
qlty Structure High total complexity (count = 66) 1
qlty Structure Function with high complexity (count = 16): mergeDict 1

@PaulaSp3 PaulaSp3 requested a review from ahuber-bfw November 25, 2025 10:18
@qltysh
Copy link
Contributor

qltysh bot commented Nov 25, 2025

Diff Coverage: The code coverage on the diff in this pull request is 9.7%.

Total Coverage: This PR will decrease coverage by 0.83%.

File Coverage Changes
Path File Coverage Δ Indirect
avaframe/com4FlowPy/flowClass.py 0.0
avaframe/com4FlowPy/flowCore.py -2.3
🛟 Help
  • Diff Coverage: Coverage for added or modified lines of code (excludes deleted files). Learn more.

  • Total Coverage: Coverage for the whole repository, calculated as the sum of all File Coverage. Learn more.

  • File Coverage: Covered Lines divided by Covered Lines plus Missed Lines. (Excludes non-executable lines including blank lines and comments.)

    • Indirect Changes: Changes to File Coverage for files that were not modified in this PR. Learn more.

fluxDistOldVersionBool=False,
FSI=None,
forestParams=None,
startcellVol=None,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function with many parameters (count = 16): __init__ [qlty:function-parameters]

if key in processedStartCellIdDict:
ids = np.append(processedStartCellIdList[i][key], processedStartCellIdDict[key])
processedStartCellIdDict[key] = np.unique(ids)
else:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deeply nested control flow (level = 4) [qlty:nested-control-flow]

startCellIdDict[(cell.rowindex, cell.colindex)], startcellId)
startCellIdDict[(cell.rowindex, cell.colindex)] = np.unique(
startcellIdList)
else:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deeply nested control flow (level = 4) [qlty:nested-control-flow]

)
else:
relVolMinArray[cell.rowindex, cell.colindex] = max(
relVolMinArray[cell.rowindex, cell.colindex], cell.startcellVolMin
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deeply nested control flow (level = 4) [qlty:nested-control-flow]

else:
mergedDict[cellind] = smallDict[cellindSmall]
mergedDict[cellind] = np.unique(mergedDict[cellind])
log.info("appended result %s_%i_%i", fName, i, j)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function with high complexity (count = 16): mergeDict [qlty:function-complexity]

if cellind in mergedDict:
mergedDict[cellind] = np.append(smallDict[cellindSmall], mergedDict[cellind])
else:
mergedDict[cellind] = smallDict[cellindSmall]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deeply nested control flow (level = 4) [qlty:nested-control-flow]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request flowPyDev Ideas for future development

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants