recommendation
sleap_nn.config_generator.tui.widgets.recommendation
¶
Recommendation panel widget.
Displays pipeline and backbone recommendations based on dataset analysis.
Classes:
| Name | Description |
|---|---|
DatasetStatsPanel |
Widget displaying dataset statistics. |
QuickSettingsPanel |
Widget showing quick summary of current settings. |
RecommendationPanel |
Widget displaying pipeline recommendation. |
DatasetStatsPanel
¶
Bases: Static
Widget displaying dataset statistics.
Shows key statistics about the loaded SLP file including frame count, image dimensions, skeleton info, and instance counts.
Methods:
| Name | Description |
|---|---|
__init__ |
Initialize with optional stats. |
render |
Render the stats panel. |
update_stats |
Update the displayed statistics. |
Source code in sleap_nn/config_generator/tui/widgets/recommendation.py
101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 | |
__init__(stats=None, **kwargs)
¶
Initialize with optional stats.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
stats
|
DatasetStats object to display. |
None
|
|
**kwargs
|
Additional arguments passed to parent. |
{}
|
Source code in sleap_nn/config_generator/tui/widgets/recommendation.py
render()
¶
Render the stats panel.
Source code in sleap_nn/config_generator/tui/widgets/recommendation.py
update_stats(stats)
¶
Update the displayed statistics.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
stats
|
New DatasetStats object. |
required |
QuickSettingsPanel
¶
Bases: Static
Widget showing quick summary of current settings.
Provides at-a-glance view of key configuration parameters.
Methods:
| Name | Description |
|---|---|
__init__ |
Initialize the panel. |
render |
Render the quick settings panel. |
update_settings |
Update displayed settings. |
Source code in sleap_nn/config_generator/tui/widgets/recommendation.py
__init__(**kwargs)
¶
render()
¶
Render the quick settings panel.
Source code in sleap_nn/config_generator/tui/widgets/recommendation.py
update_settings(pipeline='', backbone='', batch_size=0, input_scale=1.0, sigma=5.0)
¶
Update displayed settings.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pipeline
|
str
|
Pipeline type. |
''
|
backbone
|
str
|
Backbone architecture. |
''
|
batch_size
|
int
|
Batch size. |
0
|
input_scale
|
float
|
Input scaling factor. |
1.0
|
sigma
|
float
|
Confidence map sigma. |
5.0
|
Source code in sleap_nn/config_generator/tui/widgets/recommendation.py
RecommendationPanel
¶
Bases: Static
Widget displaying pipeline recommendation.
Shows the recommended pipeline type, backbone architecture, and any warnings or suggestions based on data analysis.
Methods:
| Name | Description |
|---|---|
__init__ |
Initialize with optional recommendation. |
render |
Render the recommendation panel. |
update_recommendation |
Update the displayed recommendation. |
Attributes:
| Name | Type | Description |
|---|---|---|
recommendation |
Optional[ConfigRecommendation]
|
Get the current recommendation. |
Source code in sleap_nn/config_generator/tui/widgets/recommendation.py
recommendation
property
¶
Get the current recommendation.
__init__(recommendation=None, **kwargs)
¶
Initialize with optional recommendation.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
recommendation
|
Optional[ConfigRecommendation]
|
Initial recommendation to display. |
None
|
**kwargs
|
Additional arguments passed to parent. |
{}
|
Source code in sleap_nn/config_generator/tui/widgets/recommendation.py
render()
¶
Render the recommendation panel.
Source code in sleap_nn/config_generator/tui/widgets/recommendation.py
update_recommendation(rec)
¶
Update the displayed recommendation.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
rec
|
ConfigRecommendation
|
New recommendation to display. |
required |