tictacsync 0.5a0__py3-none-any.whl → 0.6a0__py3-none-any.whl
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.
Potentially problematic release.
This version of tictacsync might be problematic. Click here for more details.
- tictacsync/entry.py +8 -8
- tictacsync/timeline.py +8 -2
- tictacsync/yaltc.py +361 -915
- {tictacsync-0.5a0.dist-info → tictacsync-0.6a0.dist-info}/METADATA +1 -1
- tictacsync-0.6a0.dist-info/RECORD +15 -0
- tictacsync-0.5a0.dist-info/RECORD +0 -15
- {tictacsync-0.5a0.dist-info → tictacsync-0.6a0.dist-info}/LICENSE +0 -0
- {tictacsync-0.5a0.dist-info → tictacsync-0.6a0.dist-info}/WHEEL +0 -0
- {tictacsync-0.5a0.dist-info → tictacsync-0.6a0.dist-info}/entry_points.txt +0 -0
- {tictacsync-0.5a0.dist-info → tictacsync-0.6a0.dist-info}/top_level.txt +0 -0
tictacsync/entry.py
CHANGED
|
@@ -72,8 +72,9 @@ def process_files(medias):
|
|
|
72
72
|
def process_single(file, args):
|
|
73
73
|
# argument is a single file
|
|
74
74
|
m = device_scanner.media_at_path(None, Path(file))
|
|
75
|
-
a_rec = yaltc.Recording(m)
|
|
76
|
-
time = a_rec.get_start_time(
|
|
75
|
+
a_rec = yaltc.Recording(m, do_plots=args.plotting)
|
|
76
|
+
time = a_rec.get_start_time()
|
|
77
|
+
# time = a_rec.get_start_time(plots=args.plotting)
|
|
77
78
|
if time != None:
|
|
78
79
|
frac_time = int(time.microsecond / 1e2)
|
|
79
80
|
d = '%s.%s'%(time.strftime("%Y-%m-%d %H:%M:%S"),frac_time)
|
|
@@ -124,10 +125,9 @@ def main():
|
|
|
124
125
|
if args.verbose_output:
|
|
125
126
|
logger.add(sys.stderr, level="DEBUG")
|
|
126
127
|
# logger.add(sys.stdout, filter="__main__")
|
|
127
|
-
# logger.add(sys.stdout, filter="
|
|
128
|
-
# logger.add(sys.stdout, filter="
|
|
129
|
-
# logger.add(sys.stdout, filter=lambda r: r["function"] == "
|
|
130
|
-
# logger.add(sys.stdout, filter=lambda r: r["function"] == "scan_media_and_build_devices_UID")
|
|
128
|
+
# logger.add(sys.stdout, filter="yaltc")
|
|
129
|
+
# logger.add(sys.stdout, filter=lambda r: r["function"] == "_read_sound_find_TicTacCode")
|
|
130
|
+
# logger.add(sys.stdout, filter=lambda r: r["function"] == "_detect_sync_pulse_position")
|
|
131
131
|
# logger.add(sys.stdout, filter=lambda r: r["function"] == "_get_device_mix")
|
|
132
132
|
# logger.add(sys.stdout, filter=lambda r: r["function"] == "_sox_mix_files")
|
|
133
133
|
top_dir = args.directory[0]
|
|
@@ -195,7 +195,7 @@ def main():
|
|
|
195
195
|
# table.add_column("Device\n", justify="center", style='gold1')
|
|
196
196
|
table.add_column("UTC times\nstart:end", justify="center", style='gold1')
|
|
197
197
|
table.add_column("Clock drift\n(ppm)", justify="right", style='gold1')
|
|
198
|
-
table.add_column("SN ratio\n(dB)", justify="center", style='gold1')
|
|
198
|
+
# table.add_column("SN ratio\n(dB)", justify="center", style='gold1')
|
|
199
199
|
table.add_column("Date\n", justify="center", style='gold1')
|
|
200
200
|
rec_WO_time = [
|
|
201
201
|
rec.AVpath.name
|
|
@@ -218,7 +218,7 @@ def main():
|
|
|
218
218
|
times_range,
|
|
219
219
|
# '%.6f'%(r.true_samplerate/1e3),
|
|
220
220
|
'%2i'%(r.get_samplerate_drift()),
|
|
221
|
-
'%.0f'%r.decoder.SN_ratio,
|
|
221
|
+
# '%.0f'%r.decoder.SN_ratio,
|
|
222
222
|
date
|
|
223
223
|
)
|
|
224
224
|
console = Console()
|
tictacsync/timeline.py
CHANGED
|
@@ -1111,6 +1111,7 @@ class Matcher:
|
|
|
1111
1111
|
videoclip))
|
|
1112
1112
|
audio_stitch = AudioStitcherVideoMerger(videoclip)
|
|
1113
1113
|
for audio in audio_recs:
|
|
1114
|
+
logger.debug('checking %s'%audio)
|
|
1114
1115
|
if self._does_overlap(videoclip, audio):
|
|
1115
1116
|
audio_stitch.add_matched_audio(audio)
|
|
1116
1117
|
logger.debug('recording %s overlaps,'%(audio))
|
|
@@ -1125,9 +1126,14 @@ class Matcher:
|
|
|
1125
1126
|
|
|
1126
1127
|
def _does_overlap(self, videoclip, audio_rec):
|
|
1127
1128
|
A1, A2 = audio_rec.get_start_time(), audio_rec.get_end_time()
|
|
1129
|
+
logger.debug('audio str stp: %s %s'%(A1,A2))
|
|
1128
1130
|
R1, R2 = videoclip.get_start_time(), videoclip.get_end_time()
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
+
logger.debug('video str stp: %s %s'%(R1,R2))
|
|
1132
|
+
case1 = A1 < R1 < A2
|
|
1133
|
+
case2 = A1 < R2 < A2
|
|
1134
|
+
case3 = R1 < A1 < R2
|
|
1135
|
+
case4 = R1 < A2 < R2
|
|
1136
|
+
return case1 or case2 or case3 or case4
|
|
1131
1137
|
|
|
1132
1138
|
def shrink_gaps_between_takes(self, with_gap=CLUSTER_GAP):
|
|
1133
1139
|
"""
|