The following should work at least for grabbing the gpx as well
def get_files(zip_path):
pattern = re.compile(r"^activities/\d+.gpx$")
with zipfile.ZipFile(zip_path) as run_zip:
good_files = [f for f in run_zip.namelist() if pattern.match(f)]
for filename in tqdm.tqdm(good_files):
yield run_zip.open(filename).read()
The following should work at least for grabbing the
gpx
as well