File tree Expand file tree Collapse file tree 2 files changed +408
-5
lines changed Expand file tree Collapse file tree 2 files changed +408
-5
lines changed Original file line number Diff line number Diff line change 66
66
67
67
# Constants
68
68
DEFAULT_HDI_PROB = 0.94
69
- DEFAULT_LOWER_QUANTILE = 0.025
70
- DEFAULT_UPPER_QUANTILE = 0.975
71
- DEFAULT_QUANTILE = 0.5
72
- DEFAULT_N_PERCENTILES = 30
73
69
74
70
75
71
class BaseMMM (BaseValidateMMM ):
@@ -449,9 +445,11 @@ def _compute_scales(self) -> None:
449
445
self .channel_scale = self ._compute_scale_for_data (
450
446
channel_data , self .scaling .channel .method , axis = 0
451
447
)
452
- self . target_scale = self ._compute_scale_for_data (
448
+ target_scale = self ._compute_scale_for_data (
453
449
target_data , self .scaling .target .method , axis = None
454
450
)
451
+ # Ensure target_scale is a Python float (convert from numpy scalar if needed)
452
+ self .target_scale = float (target_scale )
455
453
456
454
def create_idata_attrs (self ) -> dict [str , str ]:
457
455
"""Create attributes for the inference data.
You can’t perform that action at this time.
0 commit comments