Spaces:
Running
Running
Update main.py
Browse files
main.py
CHANGED
@@ -133,7 +133,7 @@ async def your_continuous_function(page: str,paginate: str):
|
|
133 |
combined_df = pd.DataFrame()
|
134 |
|
135 |
# Update the payload for each page
|
136 |
-
url = "https://report.transexpress.lk/api/orders/delivery-success-rate/return-to-client-orders?page=
|
137 |
|
138 |
payload = {}
|
139 |
headers = {
|
@@ -156,11 +156,12 @@ async def your_continuous_function(page: str,paginate: str):
|
|
156 |
df['status_name'] = df['status_name'].replace('Received by Client', 'Returned to Client')
|
157 |
|
158 |
print("data collected from page : "+page)
|
|
|
159 |
#data.to_csv("new.csv")
|
160 |
|
161 |
-
accuracy,classification_rep,message = train_the_model(df)
|
162 |
|
163 |
-
return {"message":message,"page_number":page,"data_count":data_count,"accuracy":accuracy,"classification_rep":classification_rep}
|
164 |
|
165 |
|
166 |
|
|
|
133 |
combined_df = pd.DataFrame()
|
134 |
|
135 |
# Update the payload for each page
|
136 |
+
url = "https://report.transexpress.lk/api/orders/delivery-success-rate/return-to-client-orders?page="+page+"&per_page="+paginate
|
137 |
|
138 |
payload = {}
|
139 |
headers = {
|
|
|
156 |
df['status_name'] = df['status_name'].replace('Received by Client', 'Returned to Client')
|
157 |
|
158 |
print("data collected from page : "+page)
|
159 |
+
return "done"
|
160 |
#data.to_csv("new.csv")
|
161 |
|
162 |
+
#accuracy,classification_rep,message = train_the_model(df)
|
163 |
|
164 |
+
#return {"message":message,"page_number":page,"data_count":data_count,"accuracy":accuracy,"classification_rep":classification_rep}
|
165 |
|
166 |
|
167 |
|