pixano.app.serve
App(library_dir, media_dir, models_dir=None, aws_endpoint=None, aws_region=None, aws_access_key=None, aws_secret_key=None, host='127.0.0.1', port=8000)
The Pixano app.
Attributes:
Name | Type | Description |
---|---|---|
app |
FastAPI
|
FastAPI App. |
config |
Config
|
App config. |
server |
Server
|
App server. |
Parameters:
Name | Type | Description | Default |
---|---|---|---|
library_dir
|
str
|
Local or S3 path to dataset library |
required |
media_dir
|
str
|
Local or S3 path to media library |
required |
models_dir
|
str | None
|
Path to your models. If not provided, and library_dir is not a S3 path, it is set to library_dir/models. |
None
|
aws_endpoint
|
str | None
|
S3 endpoint URL, use 'AWS' if not provided. Used if library_dir is an S3 path. |
None
|
aws_region
|
str | None
|
S3 region name, not always required for private storages. Used if library_dir is an S3 path. |
None
|
aws_access_key
|
str | None
|
S3 AWS access key. Used if library_dir is an S3 path. |
None
|
aws_secret_key
|
str | None
|
S3 AWS secret key. Used if library_dir is an S3 path. |
None
|
host
|
str
|
App host. |
'127.0.0.1'
|
port
|
int
|
App port. |
8000
|
Source code in pixano/app/serve.py
display(height=1000)
Display the Pixano app.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
height
|
int
|
Frame height. |
1000
|
Source code in pixano/app/serve.py
get_env()
Get the app's current running environment.
Returns:
Type | Description |
---|---|
str
|
Running environment. |
Source code in pixano/app/serve.py
main(library_dir, media_dir, models_dir, aws_endpoint, aws_region, aws_access_key, aws_secret_key, host, port)
Launch Pixano App in LIBRARY_DIR.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
library_dir
|
str
|
Local or S3 path to dataset library. |
required |
media_dir
|
str
|
Local or S3 path to media library. |
required |
models_dir
|
str
|
Path to your models. If not provided, and library_dir is not a S3 path, it is set to library_dir/models. |
required |
aws_endpoint
|
str
|
S3 endpoint URL, use 'AWS' if not provided. |
required |
aws_region
|
str
|
S3 region name, not always required for private storages. |
required |
aws_access_key
|
str
|
S3 AWS access key. |
required |
aws_secret_key
|
str
|
S3 AWS secret key. |
required |
host
|
str
|
App host. |
required |
port
|
int
|
App port. |
required |
Source code in pixano/app/serve.py
192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 |
|