batchalign 0.8.2.post6__tar.gz → 0.8.2.post7__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {batchalign-0.8.2.post6/batchalign.egg-info → batchalign-0.8.2.post7}/PKG-INFO +1 -1
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/analysis/compare.py +44 -16
- batchalign-0.8.2.post7/batchalign/version +3 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7/batchalign.egg-info}/PKG-INFO +1 -1
- batchalign-0.8.2.post6/batchalign/version +0 -3
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/LICENSE +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/MANIFEST.in +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/README.md +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/__main__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/cli/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/cli/bench.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/cli/cache.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/cli/cli.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/cli/dispatch.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/constants.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/document.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/errors.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/base.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/chat/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/chat/file.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/chat/generator.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/chat/lexer.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/chat/parser.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/chat/utils.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/textgrid/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/textgrid/file.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/textgrid/generator.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/formats/textgrid/parser.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/audio_io.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/resolve.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/speaker/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/speaker/config.yaml +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/speaker/infer.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/speaker/utils.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/training/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/training/run.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/training/utils.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/utils.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/utterance/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/utterance/cantonese_infer.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/utterance/dataset.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/utterance/execute.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/utterance/infer.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/utterance/prep.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/utterance/train.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/wave2vec/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/wave2vec/infer_fa.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/whisper/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/whisper/infer_asr.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/whisper/infer_fa.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/analysis/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/analysis/eval.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2chinese.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/deu.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/ell.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/eng.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/eus.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/fra.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/hrv.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/ind.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/jpn.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/nld.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/por.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/spa.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/tha.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/oai_whisper.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/rev.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/utils.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/whisper.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/whisperx.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/avqi/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/avqi/engine.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/base.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cache.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/cleanup.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/disfluencies.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/parse_support.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/retrace.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/support/filled_pauses.eng +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/support/replacements.eng +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/support/test.test +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/diarization/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/diarization/pyannote.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/dispatch.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/fa/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/fa/wave2vec_fa.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/fa/whisper_fa.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/coref.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/en/irr.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/fr/apm.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/fr/apmn.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/fr/case.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/ja/verbforms.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/ud.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/opensmile/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/opensmile/engine.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/pipeline.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/speaker/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/speaker/nemo_speaker.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/translate/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/translate/gtrans.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/translate/seamless.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/translate/utils.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/utr/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/utr/rev_utr.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/utr/utils.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/utr/whisper_utr.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/utterance/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/utterance/ud_utterance.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/cli/test_dispatch_memory.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/conftest.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/chat/test_chat_file.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/chat/test_chat_generator.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/chat/test_chat_lexer.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/chat/test_chat_parser.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/chat/test_chat_utils.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/textgrid/test_textgrid.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/models/test_audio_io.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/models/test_audio_lazy.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/analysis/test_eval.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/asr/test_asr_pipeline.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/asr/test_asr_utils.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/cache/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/cache/test_cache.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/cleanup/test_disfluency.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/cleanup/test_parse_support.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/fa/test_fa_pipeline.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/fa/test_fa_short_segments.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/fixures.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/test_pipeline.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/test_pipeline_models.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/test_document.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/utils/__init__.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/utils/abbrev.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/utils/compounds.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/utils/config.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/utils/device.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/utils/dp.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/utils/names.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/utils/utils.py +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign.egg-info/SOURCES.txt +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign.egg-info/dependency_links.txt +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign.egg-info/entry_points.txt +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign.egg-info/requires.txt +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign.egg-info/top_level.txt +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/setup.cfg +0 -0
- {batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/setup.py +0 -0
|
@@ -329,6 +329,10 @@ class CompareEngine(BatchalignEngine):
|
|
|
329
329
|
# window in the remaining main tokens, then run Levenshtein inside
|
|
330
330
|
# that window to produce the annotations.
|
|
331
331
|
utt_positioned = {i: [] for i in range(len(gold_utterances))}
|
|
332
|
+
# Track which main (child) forms land in each gold utterance's window
|
|
333
|
+
utt_main_forms = {i: [] for i in range(len(gold_utterances))}
|
|
334
|
+
# Track which main utterance(s) contribute to each gold utterance
|
|
335
|
+
utt_main_speakers = {i: [] for i in range(len(gold_utterances))}
|
|
332
336
|
search_start = 0
|
|
333
337
|
|
|
334
338
|
for utt_idx in range(len(gold_utterances)):
|
|
@@ -345,6 +349,17 @@ class CompareEngine(BatchalignEngine):
|
|
|
345
349
|
abs_start = search_start + win_start
|
|
346
350
|
abs_end = search_start + win_end
|
|
347
351
|
|
|
352
|
+
# Collect unique main forms in the window (deduplicate
|
|
353
|
+
# across conformed expansions that map to the same form)
|
|
354
|
+
seen_main = set()
|
|
355
|
+
for j in range(abs_start, abs_end):
|
|
356
|
+
orig_idx = main_map[j]
|
|
357
|
+
if orig_idx not in seen_main:
|
|
358
|
+
seen_main.add(orig_idx)
|
|
359
|
+
m_utt_idx, m_form_idx, m_form = main_info[orig_idx]
|
|
360
|
+
utt_main_forms[utt_idx].append(m_form)
|
|
361
|
+
utt_main_speakers[utt_idx].append(m_utt_idx)
|
|
362
|
+
|
|
348
363
|
# Align the chosen window against this gold utterance
|
|
349
364
|
window_main = conformed_main[abs_start:abs_end]
|
|
350
365
|
utt_alignment = align(window_main, g_tokens, False, match_fn)
|
|
@@ -363,11 +378,6 @@ class CompareEngine(BatchalignEngine):
|
|
|
363
378
|
gold_form = gold_info[orig_gold_idx][2]
|
|
364
379
|
last_gold_form_idx = gold_form_idx
|
|
365
380
|
|
|
366
|
-
# Copy timing from main; keep gold's own morphology
|
|
367
|
-
if main_form.time is not None:
|
|
368
|
-
gold_form.time = main_form.time
|
|
369
|
-
gold_form.dependency = None
|
|
370
|
-
|
|
371
381
|
utt_positioned[utt_idx].append((gold_form_idx, CompareToken(
|
|
372
382
|
text=item.key,
|
|
373
383
|
pos=_get_pos(gold_form),
|
|
@@ -383,8 +393,6 @@ class CompareEngine(BatchalignEngine):
|
|
|
383
393
|
gold_form = gold_info[orig_gold_idx][2]
|
|
384
394
|
last_gold_form_idx = gold_form_idx
|
|
385
395
|
|
|
386
|
-
gold_form.dependency = None
|
|
387
|
-
|
|
388
396
|
utt_positioned[utt_idx].append((gold_form_idx, CompareToken(
|
|
389
397
|
text=item.key,
|
|
390
398
|
pos=_get_pos(gold_form),
|
|
@@ -415,21 +423,41 @@ class CompareEngine(BatchalignEngine):
|
|
|
415
423
|
pos="PUNCT",
|
|
416
424
|
status="match"
|
|
417
425
|
)))
|
|
418
|
-
# Ensure punctuation forms have morphology so %mor includes
|
|
419
|
-
# the final delimiter (matches generator's PUNCT|<char> logic)
|
|
420
|
-
if form.morphology is None:
|
|
421
|
-
form.morphology = [Morphology(
|
|
422
|
-
pos="PUNCT", lemma=form.text.strip(), feats=""
|
|
423
|
-
)]
|
|
424
|
-
form.dependency = None
|
|
425
426
|
utt_positioned[utt_idx].sort(key=lambda x: x[0])
|
|
426
427
|
|
|
427
|
-
# --- 7.
|
|
428
|
+
# --- 7. Replace each gold utterance's main line with the child's
|
|
429
|
+
# (main/proposal) forms and set the child's speaker. ---
|
|
428
430
|
for utt_idx, utt in enumerate(gold_utterances):
|
|
429
431
|
tokens = [tok for _, tok in utt_positioned[utt_idx]]
|
|
430
432
|
utt.comparison = tokens if tokens else None
|
|
431
433
|
|
|
432
|
-
|
|
434
|
+
# Replace content with the child/main forms from the window
|
|
435
|
+
child_forms = utt_main_forms[utt_idx]
|
|
436
|
+
if child_forms:
|
|
437
|
+
# Grab the ending punctuation from gold so the utterance
|
|
438
|
+
# delimiter is preserved
|
|
439
|
+
gold_ending = [
|
|
440
|
+
f for f in utt.content
|
|
441
|
+
if f.text.strip() in ENDING_PUNCT
|
|
442
|
+
]
|
|
443
|
+
# Strip dependency from child forms (morphosyntax was run
|
|
444
|
+
# on the main doc separately; gold structure differs)
|
|
445
|
+
for f in child_forms:
|
|
446
|
+
f.dependency = None
|
|
447
|
+
utt.content = child_forms + gold_ending
|
|
448
|
+
|
|
449
|
+
# Set speaker from the child utterance that contributed
|
|
450
|
+
# the most forms to this window
|
|
451
|
+
speaker_indices = utt_main_speakers[utt_idx]
|
|
452
|
+
if speaker_indices:
|
|
453
|
+
# Pick the most common main utterance index
|
|
454
|
+
majority_utt_idx = max(
|
|
455
|
+
set(speaker_indices), key=speaker_indices.count
|
|
456
|
+
)
|
|
457
|
+
utt.tier = main_utterances[majority_utt_idx].tier
|
|
458
|
+
|
|
459
|
+
# Derive utterance timing from the (now-child) forms
|
|
460
|
+
timed_forms = [f for f in utt.content if f.time is not None]
|
|
433
461
|
if timed_forms:
|
|
434
462
|
utt.time = (timed_forms[0].time[0], timed_forms[-1].time[1])
|
|
435
463
|
utt.text = None
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/models/utterance/cantonese_infer.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/asr/num2lang/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/disfluencies.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/parse_support.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/cleanup/support/test.test
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/diarization/__init__.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/diarization/pyannote.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/__init__.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/coref.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/en/irr.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/fr/apm.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/fr/apmn.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/fr/case.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/morphosyntax/ja/verbforms.py
RENAMED
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/opensmile/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/speaker/nemo_speaker.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/translate/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/translate/seamless.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/utterance/__init__.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/pipelines/utterance/ud_utterance.py
RENAMED
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/cli/test_dispatch_memory.py
RENAMED
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/chat/test_chat_file.py
RENAMED
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/chat/test_chat_lexer.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/chat/test_chat_parser.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/chat/test_chat_utils.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/formats/textgrid/test_textgrid.py
RENAMED
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/models/test_audio_lazy.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/analysis/test_eval.py
RENAMED
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/asr/test_asr_utils.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/cache/__init__.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/cache/test_cache.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/fa/test_fa_pipeline.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/test_pipeline.py
RENAMED
|
File without changes
|
{batchalign-0.8.2.post6 → batchalign-0.8.2.post7}/batchalign/tests/pipelines/test_pipeline_models.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|