Context
Whether rearing habitat must be spatially connected to spawning is a significant modelling decision that affects habitat estimates by 25-35%. Different use cases need different answers. link controls what break sources and parameters are fed to fresh — this is link's domain decision, not fresh's.
How bcfishpass (v0.5.0) implements rearing connectivity
Three sequential phases in load_habitat_linear_bt.sql (same pattern for CO, ST, all species):
Phase 1 — Rearing on spawning streams: Segment is already spawning AND meets rearing thresholds → rearing. No connectivity check.
Phase 2 — Rearing downstream of spawning: Cluster adjacent rearing-candidate segments (ST_ClusterDBSCAN(geom, 1, 1)). If spawning exists anywhere upstream of the cluster → entire cluster is rearing. No distance cap, no gradient barrier check. Biologically: juveniles drift/swim downstream easily.
Phase 3 — Rearing upstream of spawning: Same clustering, but traces downstream along mainstem. If spawning exists within 10km downstream AND no segment ≥5% gradient between rearing and spawning → rearing. The 5% bridge threshold and 10km cap are hardcoded for all species.
Where it makes sense
Coho on a small coastal stream:
3m wide, 2% gradient → SPAWNING (≥2m, ≤5.49%) + REARING (Phase 1)
2m wide, 1% gradient → REARING (Phase 2: downstream, spawning upstream)
1.5m wide, 3% gradient → REARING (Phase 2: still downstream of spawning)
CO spawn and rear in the same small streams. Connectivity requirement is biologically sound — rearing without nearby spawning means no fish.
Bull trout, headwater to mainstem:
2m wide, 4% gradient, cold headwater → SPAWNING (≥2m, ≤5.49%)
8m wide, 1% gradient, mainstem 15km downstream → REARING (Phase 2, no distance cap)
BT spawn in cold headwaters, juveniles migrate downstream. Phase 2 handles this — no distance cap going downstream.
Where it gives false negatives
Steelhead, narrow tributary:
2m wide, 3% gradient → meets ST rearing thresholds (≥1.5m, ≤8.49%)
but NO steelhead spawning anywhere nearby
(ST spawning requires ≥4m channel width)
Result: no ST rearing classified. The stream is excellent rearing habitat but no spawning is modelled on it because the channel is too narrow for ST spawning (min 4m). The connectivity rule creates a false negative because the spawning width threshold is stricter than the rearing width threshold.
Rearing above a steep section:
2m wide, 2% gradient → rearing candidate (upstream)
2m wide, 7% gradient → exceeds 5% bridge threshold
4m wide, 3% gradient → SPAWNING (downstream)
Phase 3 traces downstream from the rearing, finds 7% between it and spawning → rearing excluded. But bull trout juveniles can navigate steeper terrain than coho. The 5% bridge threshold is hardcoded for all species in bcfishpass v0.5.0 — a species-specific threshold would be more biologically accurate.
Isolated quality habitat (restoration prioritization):
3m wide, 2% gradient, 15km of stream meeting all rearing thresholds
No spawning within 10km in any direction
Barrier crossing downstream — if fixed, would connect to spawning
bcfishpass: not rearing. For current-state assessment this is correct — no fish there now. But for prioritization (link's purpose), this is exactly the habitat you want to quantify: how much rearing would be unlocked by fixing that crossing?
Directional asymmetry
Phase 2 (downstream) has no gradient barrier check — juveniles drift down past steep sections easily. Phase 3 (upstream) requires no ≥5% grade between rearing and spawning — juveniles can't swim up past 5%. This directional logic is biologically sound but the 5% threshold should vary by species (BT can navigate steeper terrain than CO).
Proposed Solution
link should support configurable rearing-spawning connectivity as parameters in the thresholds CSV. New columns:
| Column |
Description |
bcfishpass v0.5.0 value |
rear_spawn_bridge_gradient |
Max gradient between rearing and spawning for upstream connectivity (Phase 3) |
0.05 (all species) |
rear_spawn_bridge_distance |
Max distance upstream from spawning to include rearing (Phase 3) |
10000m (all species) |
When both are NA or the connectivity check is disabled, rearing is classified independently on gradient + channel width — useful for restoration potential analysis.
When set, link would need to implement the cluster analysis (Phases 2 + 3) as a post-processing step on fresh output, or fresh would need a connectivity-aware classification mode.
The gated vs ungated comparison (gate parameter, fresh#98) already lets users compare total habitat potential vs access-restricted habitat. The rearing connectivity adds a third layer: total → accessible → connected-to-spawning.
References
Relates to NewGraphEnvironment/fresh#98, NewGraphEnvironment/fresh#101
Context
Whether rearing habitat must be spatially connected to spawning is a significant modelling decision that affects habitat estimates by 25-35%. Different use cases need different answers. link controls what break sources and parameters are fed to fresh — this is link's domain decision, not fresh's.
How bcfishpass (v0.5.0) implements rearing connectivity
Three sequential phases in
load_habitat_linear_bt.sql(same pattern for CO, ST, all species):Phase 1 — Rearing on spawning streams: Segment is already spawning AND meets rearing thresholds → rearing. No connectivity check.
Phase 2 — Rearing downstream of spawning: Cluster adjacent rearing-candidate segments (
ST_ClusterDBSCAN(geom, 1, 1)). If spawning exists anywhere upstream of the cluster → entire cluster is rearing. No distance cap, no gradient barrier check. Biologically: juveniles drift/swim downstream easily.Phase 3 — Rearing upstream of spawning: Same clustering, but traces downstream along mainstem. If spawning exists within 10km downstream AND no segment ≥5% gradient between rearing and spawning → rearing. The 5% bridge threshold and 10km cap are hardcoded for all species.
Where it makes sense
Coho on a small coastal stream:
CO spawn and rear in the same small streams. Connectivity requirement is biologically sound — rearing without nearby spawning means no fish.
Bull trout, headwater to mainstem:
BT spawn in cold headwaters, juveniles migrate downstream. Phase 2 handles this — no distance cap going downstream.
Where it gives false negatives
Steelhead, narrow tributary:
Result: no ST rearing classified. The stream is excellent rearing habitat but no spawning is modelled on it because the channel is too narrow for ST spawning (min 4m). The connectivity rule creates a false negative because the spawning width threshold is stricter than the rearing width threshold.
Rearing above a steep section:
Phase 3 traces downstream from the rearing, finds 7% between it and spawning → rearing excluded. But bull trout juveniles can navigate steeper terrain than coho. The 5% bridge threshold is hardcoded for all species in bcfishpass v0.5.0 — a species-specific threshold would be more biologically accurate.
Isolated quality habitat (restoration prioritization):
bcfishpass: not rearing. For current-state assessment this is correct — no fish there now. But for prioritization (link's purpose), this is exactly the habitat you want to quantify: how much rearing would be unlocked by fixing that crossing?
Directional asymmetry
Phase 2 (downstream) has no gradient barrier check — juveniles drift down past steep sections easily. Phase 3 (upstream) requires no ≥5% grade between rearing and spawning — juveniles can't swim up past 5%. This directional logic is biologically sound but the 5% threshold should vary by species (BT can navigate steeper terrain than CO).
Proposed Solution
link should support configurable rearing-spawning connectivity as parameters in the thresholds CSV. New columns:
rear_spawn_bridge_gradientrear_spawn_bridge_distanceWhen both are
NAor the connectivity check is disabled, rearing is classified independently on gradient + channel width — useful for restoration potential analysis.When set, link would need to implement the cluster analysis (Phases 2 + 3) as a post-processing step on fresh output, or fresh would need a connectivity-aware classification mode.
The gated vs ungated comparison (
gateparameter, fresh#98) already lets users compare total habitat potential vs access-restricted habitat. The rearing connectivity adds a third layer: total → accessible → connected-to-spawning.References
load_habitat_linear_bt.sqlload_habitat_linear_co.sqlRelates to NewGraphEnvironment/fresh#98, NewGraphEnvironment/fresh#101