chenemii commited on
Commit
be88a1a
·
1 Parent(s): cb404fd

remove counting

Browse files
Files changed (3) hide show
  1. app/main.py +1 -15
  2. app/streamlit_app.py +1 -27
  3. requirements.txt +0 -1
app/main.py CHANGED
@@ -92,21 +92,7 @@ def main():
92
  sample_rate=sample_rate)
93
  print(f"Annotated video saved to: {output_path}")
94
 
95
- # Log swing analysis to Trackio
96
- try:
97
- import trackio
98
- trackio.init(project="par-ity-golf-swing", config={
99
- "input_method": "cli",
100
- "sample_rate": sample_rate
101
- })
102
- trackio.log({
103
- "swings_analyzed": 1,
104
- "frames_processed": len(frames) if frames is not None else 0,
105
- "num_detections": len(detections) if detections is not None else 0
106
- })
107
- trackio.finish()
108
- except Exception as _trackio_err:
109
- print(f"Trackio logging skipped: {_trackio_err}")
110
 
111
  print("\nAnalysis complete!")
112
 
 
92
  sample_rate=sample_rate)
93
  print(f"Annotated video saved to: {output_path}")
94
 
95
+ # Telemetry removed per request
 
 
 
 
 
 
 
 
 
 
 
 
 
 
96
 
97
  print("\nAnalysis complete!")
98
 
app/streamlit_app.py CHANGED
@@ -791,33 +791,7 @@ def main():
791
 
792
  # Show action buttons and their results (only if analysis is complete)
793
  if st.session_state.video_analyzed:
794
- # Best-effort Trackio logging once per analyzed video (async, non-blocking)
795
- if not st.session_state.get("_trackio_logged_once"):
796
- try:
797
- import threading
798
- def _log_trackio_async():
799
- try:
800
- import trackio
801
- data = st.session_state.analysis_data
802
- frames = data.get('frames')
803
- detections = data.get('detections')
804
- trackio.init(project="par-ity-golf-swing", config={
805
- "input_method": "YouTube URL" if isinstance(data.get('video_path'), str) and 'youtube' in data.get('video_path', '').lower() else "upload",
806
- "sample_rate": data.get('sample_rate', 1)
807
- })
808
- trackio.log({
809
- "swings_analyzed": 1,
810
- "frames_processed": len(frames) if frames is not None else 0,
811
- "num_detections": len(detections) if detections is not None else 0
812
- })
813
- trackio.finish()
814
- except Exception:
815
- pass
816
- t = threading.Thread(target=_log_trackio_async, daemon=True)
817
- t.start()
818
- st.session_state._trackio_logged_once = True
819
- except Exception:
820
- pass
821
 
822
  # Display the GPT prompt in an expander
823
  if 'prompt' in st.session_state.analysis_data:
 
791
 
792
  # Show action buttons and their results (only if analysis is complete)
793
  if st.session_state.video_analyzed:
794
+ # Trackio/telemetry removed per request
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
795
 
796
  # Display the GPT prompt in an expander
797
  if 'prompt' in st.session_state.analysis_data:
requirements.txt CHANGED
@@ -17,4 +17,3 @@ scikit-learn==1.3.2
17
  plotly==5.17.0
18
  tiktoken==0.5.2
19
  transformers>=4.20.0
20
- trackio
 
17
  plotly==5.17.0
18
  tiktoken==0.5.2
19
  transformers>=4.20.0