Quellcode durchsuchen

fix bugs in ai/video analysis

张许妍 vor 3 Jahren
Ursprung
Commit
e52d550331

+ 1 - 2
backend_refactor/service/photo_analyzer.py

@@ -48,8 +48,7 @@ class StandingPhotoAnalyzer(BasePhotoAnalyzer):
                 cv2.imwrite(UPLOAD_DIR + '{}.result.jpg'.format(i), canvas)
                 photos.append(UPLOAD_DIR + '{}.result.jpg'.format(i))
 
-            callback("FINISHED", result={"photos": {"front": photos[0], "right": photos[1]},
-                                         "advice": {"front": npys[0], "right": npys[1]}})
+            callback("FINISHED", result={"analysis": {"advice": {"front": npys[0], "right": npys[1]}}})
         except Exception as e:
             callback("ERROR", error=e)
             raise e

+ 1 - 5
frontend_refactor/public/index.html

@@ -5,10 +5,6 @@
     <link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
     <meta name="viewport" content="width=device-width, initial-scale=1" />
     <meta name="theme-color" content="#000000" />
-    <meta
-      name="description"
-      content="Web site created using create-react-app"
-    />
     <link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
     <!--
       manifest.json provides metadata used when your web app is installed on a
@@ -24,7 +20,7 @@
       work correctly both with client-side routing and a non-root public URL.
       Learn how to configure a non-root public URL by running `npm run build`.
     -->
-    <title>React App</title>
+    <title>Openpose</title>
   </head>
   <body>
     <noscript>You need to enable JavaScript to run this app.</noscript>

+ 1 - 1
frontend_refactor/src/containers/TaskList.js

@@ -46,7 +46,7 @@ class TaskList extends React.Component {
                             let raw = ""
 
                             try {
-                                raw = JSON.stringify(details.result.raw)
+                                raw = JSON.stringify(details)
                                 data = JSON.stringify(details.result.analysis.data)
                                 advice = JSON.stringify(details.result.analysis.advice)
                             } catch (e) {