Spaces:
Running
on
Zero
Running
on
Zero
Update breed_recommendation.py
Browse files- breed_recommendation.py +16 -10
breed_recommendation.py
CHANGED
@@ -130,17 +130,20 @@ def create_recommendation_tab(UserPreferences, get_breed_recommendations, format
|
|
130 |
try:
|
131 |
user_prefs = UserPreferences(
|
132 |
living_space=args[0],
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
-
|
137 |
-
|
138 |
-
|
|
|
|
|
|
|
139 |
space_for_play=True if args[0] != "apartment" else False,
|
140 |
other_pets=False,
|
141 |
climate="moderate",
|
142 |
-
health_sensitivity="medium",
|
143 |
-
barking_acceptance=args[
|
144 |
)
|
145 |
|
146 |
recommendations = get_breed_recommendations(user_prefs, top_n=10)
|
@@ -487,12 +490,15 @@ def create_recommendation_tab(UserPreferences, get_breed_recommendations, format
|
|
487 |
fn=on_find_match_click,
|
488 |
inputs=[
|
489 |
living_space,
|
|
|
490 |
exercise_time,
|
|
|
491 |
grooming_commitment,
|
492 |
experience_level,
|
|
|
493 |
has_children,
|
494 |
-
|
495 |
-
|
496 |
],
|
497 |
outputs=recommendation_output
|
498 |
)
|
|
|
130 |
try:
|
131 |
user_prefs = UserPreferences(
|
132 |
living_space=args[0],
|
133 |
+
yard_access=args[1],
|
134 |
+
exercise_time=args[2],
|
135 |
+
exercise_type=args[3],
|
136 |
+
grooming_commitment=args[4],
|
137 |
+
experience_level=args[5],
|
138 |
+
time_availability=args[6],
|
139 |
+
has_children=args[7],
|
140 |
+
children_age=args[8] if args[7] else None,
|
141 |
+
noise_tolerance=args[9],
|
142 |
space_for_play=True if args[0] != "apartment" else False,
|
143 |
other_pets=False,
|
144 |
climate="moderate",
|
145 |
+
health_sensitivity="medium",
|
146 |
+
barking_acceptance=args[9]
|
147 |
)
|
148 |
|
149 |
recommendations = get_breed_recommendations(user_prefs, top_n=10)
|
|
|
490 |
fn=on_find_match_click,
|
491 |
inputs=[
|
492 |
living_space,
|
493 |
+
yard_access,
|
494 |
exercise_time,
|
495 |
+
exercise_type,
|
496 |
grooming_commitment,
|
497 |
experience_level,
|
498 |
+
time_availability,
|
499 |
has_children,
|
500 |
+
children_age,
|
501 |
+
noise_tolerance
|
502 |
],
|
503 |
outputs=recommendation_output
|
504 |
)
|