Created
November 18, 2014 20:35
-
-
Save stevedoyle/63244ddba02d2347d0d9 to your computer and use it in GitHub Desktop.
Use xpath to find all nodes of a given name
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from lxml import objectify | |
tree = objectify.parse(tcx_file') | |
root = tree.getroot() | |
root.xpath('//ns:HeartRateBpm', namespaces={'ns': 'http://www.garmin.com/xmlschemas/TrainingCenterDatabase/v2'} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment