Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -476,7 +476,7 @@ def main():
|
|
476 |
dog_style_transfer = DogStyleTransfer()
|
477 |
|
478 |
with gr.Tabs():
|
479 |
-
# 1.
|
480 |
example_images = [
|
481 |
'Border_Collie.jpg',
|
482 |
'Golden_Retriever.jpeg',
|
@@ -486,7 +486,7 @@ def main():
|
|
486 |
]
|
487 |
detection_components = create_detection_tab(predict, example_images)
|
488 |
|
489 |
-
# 2.
|
490 |
comparison_components = create_comparison_tab(
|
491 |
dog_breeds=dog_breeds,
|
492 |
get_dog_description=get_dog_description,
|
@@ -494,7 +494,7 @@ def main():
|
|
494 |
breed_noise_info=breed_noise_info
|
495 |
)
|
496 |
|
497 |
-
# 3.
|
498 |
recommendation_components = create_recommendation_tab(
|
499 |
UserPreferences=UserPreferences,
|
500 |
get_breed_recommendations=get_breed_recommendations,
|
@@ -502,7 +502,7 @@ def main():
|
|
502 |
history_component=history_component
|
503 |
)
|
504 |
|
505 |
-
# 4.
|
506 |
with gr.Tab("Visualization Analysis"):
|
507 |
create_visualization_tab(
|
508 |
dog_breeds=dog_breeds,
|
@@ -510,9 +510,12 @@ def main():
|
|
510 |
calculate_compatibility_score=calculate_compatibility_score,
|
511 |
UserPreferences=UserPreferences
|
512 |
)
|
513 |
-
|
514 |
|
515 |
-
# 5.
|
|
|
|
|
|
|
|
|
516 |
create_history_tab(history_component)
|
517 |
|
518 |
# Footer
|
|
|
476 |
dog_style_transfer = DogStyleTransfer()
|
477 |
|
478 |
with gr.Tabs():
|
479 |
+
# 1. breed detection
|
480 |
example_images = [
|
481 |
'Border_Collie.jpg',
|
482 |
'Golden_Retriever.jpeg',
|
|
|
486 |
]
|
487 |
detection_components = create_detection_tab(predict, example_images)
|
488 |
|
489 |
+
# 2. breed comparison
|
490 |
comparison_components = create_comparison_tab(
|
491 |
dog_breeds=dog_breeds,
|
492 |
get_dog_description=get_dog_description,
|
|
|
494 |
breed_noise_info=breed_noise_info
|
495 |
)
|
496 |
|
497 |
+
# 3. breed recommendation
|
498 |
recommendation_components = create_recommendation_tab(
|
499 |
UserPreferences=UserPreferences,
|
500 |
get_breed_recommendations=get_breed_recommendations,
|
|
|
502 |
history_component=history_component
|
503 |
)
|
504 |
|
505 |
+
# 4. Visualization Analysis
|
506 |
with gr.Tab("Visualization Analysis"):
|
507 |
create_visualization_tab(
|
508 |
dog_breeds=dog_breeds,
|
|
|
510 |
calculate_compatibility_score=calculate_compatibility_score,
|
511 |
UserPreferences=UserPreferences
|
512 |
)
|
|
|
513 |
|
514 |
+
# 5. Style Transfer tab
|
515 |
+
with gr.Tab("Style Transfer"):
|
516 |
+
style_transfer_components = create_style_transfer_tab(dog_style_transfer)
|
517 |
+
|
518 |
+
# 6. History Search
|
519 |
create_history_tab(history_component)
|
520 |
|
521 |
# Footer
|