MCPcopy Create free account
hub / github.com/chinobing/FastAPI-PaddleSpeech-Audio-To-Text / get_db

Function get_db

pstext/crud.py:8–13  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

6from pstext.database import SessionLocal
7
8def get_db():
9 db = SessionLocal()
10 try:
11 yield db
12 finally:
13 db.close()
14
15def get_audio_segment_data(db:Session, audio_id: int):
16 return db.query(models.Data).filter(models.Data.audio_id == audio_id).all()

Callers 2

update_audioFunction · 0.70
update_audio_segmentFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected