In [2]:
#!/usr/bin/env python

pynztacam


In [2]:


In [3]:
import xmltodict

In [4]:
thexml = ('<?xml version=\'1.0\' encoding=\'UTF-8\'?><tns:getCamerasResponse xmlns:rem="http://remote.service.callcenter.nzta.govt.nz" xmlns:tns="https://infoconnect.highwayinfo.govt.nz/schemas/camera" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><tns:camera><tns:id>130</tns:id><tns:name>SH16 1 Bond St</tns:name><tns:description>Bond St looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/130.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/130</tns:viewUrl><tns:mapx>142</tns:mapx><tns:mapy>229</tns:mapy><tns:congestionLocation><tns:name>St Lukes Rd - Newton Rd</tns:name><tns:direction>Eastbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Newton Rd - St Lukes Rd</tns:name><tns:direction>Westbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>140</tns:id><tns:name>SH16 2 Gt North Rd</tns:name><tns:description>Gt North Road looking west</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/140.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/140</tns:viewUrl><tns:mapx>113</tns:mapx><tns:mapy>232</tns:mapy><tns:congestionLocation><tns:name>Rosebank Rd - Great Nth Rd Waterview</tns:name><tns:direction>Eastbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Great Nth Rd Waterview - Rosebank Rd</tns:name><tns:direction>Westbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>150</tns:id><tns:name>SH16 3 Te Atatu Rd</tns:name><tns:description>Te Atatu Road looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/150.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/150</tns:viewUrl><tns:mapx>70</tns:mapx><tns:mapy>216</tns:mapy><tns:congestionLocation><tns:name>Te Atatu Rd - Rosebank Rd</tns:name><tns:direction>Eastbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Rosebank Rd - Te Atatu Rd</tns:name><tns:direction>Westbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>160</tns:id><tns:name>SH16 4 Lincoln Rd E</tns:name><tns:description>Lincoln Rd  looking west</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/160.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/160</tns:viewUrl><tns:mapx>52</tns:mapx><tns:mapy>207</tns:mapy><tns:congestionLocation><tns:name>Te Atatu Rd - Lincoln Rd</tns:name><tns:direction>Westbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Lincoln Rd - Te Atatu Rd</tns:name><tns:direction>Eastbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>170</tns:id><tns:name>SH16 5 Lincoln Rd W</tns:name><tns:description>Lincoln Rd looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/170.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/170</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy><tns:congestionLocation><tns:name>Lincoln Rd - Royal Rd</tns:name><tns:direction>Westbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Royal Rd - Lincoln Rd</tns:name><tns:direction>Eastbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>270</tns:id><tns:name>SH16 6 Hobsonville W</tns:name><tns:description>Hobsonville looking West towards Kumeu</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/270.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/270</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>271</tns:id><tns:name>SH16 7 Hobsonville E</tns:name><tns:description>Hobsonville Road looking East</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/271.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/271</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>221</tns:id><tns:name>SH18 Trig Rd</tns:name><tns:description>Trig Rd looking west</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/221.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/221</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>222</tns:id><tns:name>SH18 Waiahora Creek</tns:name><tns:description>Upper harbour motorway looking west</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/222.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/222</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>223</tns:id><tns:name>SH18 Brigham Creek</tns:name><tns:description>Upper harbour motorway looking East</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/223.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/223</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>224</tns:id><tns:name>SH18 Sinton Rd</tns:name><tns:description>Upper harbour motorway looking west</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/224.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/224</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>225</tns:id><tns:name>SH18 Squadron Dr</tns:name><tns:description>Upper harbour motorway looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/225.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/225</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>171</tns:id><tns:name>SH18 6 Tauhinu BRG</tns:name><tns:description>Tauhinu bridge looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/171.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/171</tns:viewUrl><tns:mapx>60</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>172</tns:id><tns:name>SH18 7 Albany HWY</tns:name><tns:description>Albany Highway Looking East</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/172.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/172</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>173</tns:id><tns:name>SH18 8 Tauhinu East</tns:name><tns:description>Tauhinu East Looking East</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/173.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/173</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>174</tns:id><tns:name>SH18 9 Paul Matthews</tns:name><tns:description>Paul matthews looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/174.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/174</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>175</tns:id><tns:name>SH18 10 Greenhithe</tns:name><tns:description>Greenhithe Rd looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/175.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/175</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>176</tns:id><tns:name>SH18 11 George Deane</tns:name><tns:description>George deane looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/176.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/176</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>177</tns:id><tns:name>SH18 12 Upper Hbr CW</tns:name><tns:description>Upper harbour looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/177.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/177</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>178</tns:id><tns:name>SH18 13 Wicklam Lane</tns:name><tns:description>Wicklam Lane looking west</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/178.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/178</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>10</tns:id><tns:name>SH1 1 Greville Rd</tns:name><tns:description>Greville road looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/10.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/10</tns:viewUrl><tns:mapx>125</tns:mapx><tns:mapy>71</tns:mapy><tns:congestionLocation><tns:name>Upper Harb Hwy - Oteha Valley Rd</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Oteha Valley Rd - Upper Harb Hwy</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>20</tns:id><tns:name>SH1 2 Tristram Ave</tns:name><tns:description>Tristram Avenue looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/20.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/20</tns:viewUrl><tns:mapx>148</tns:mapx><tns:mapy>118</tns:mapy><tns:congestionLocation><tns:name>Tristram Ave - Esmonde Rd</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Esmonde Rd - Tristram Ave</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>30</tns:id><tns:name>SH1 3 Northcote Rd</tns:name><tns:description>Northcote Rd looking north</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/30.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/30</tns:viewUrl><tns:mapx>156</tns:mapx><tns:mapy>141</tns:mapy><tns:congestionLocation><tns:name>Tristram Ave - Esmonde Rd</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Esmonde Rd - Tristram Ave</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>40</tns:id><tns:name>SH1 4 Esmonde Rd</tns:name><tns:description>Esmonde Rd looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/40.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/40</tns:viewUrl><tns:mapx>178</tns:mapx><tns:mapy>146</tns:mapy><tns:congestionLocation><tns:name>Esmonde Rd - Onewa</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Stafford Rd - Esmonde Rd</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>50</tns:id><tns:name>SH1 5 Onewa Rd</tns:name><tns:description>Onewa Rd looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/50.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/50</tns:viewUrl><tns:mapx>157</tns:mapx><tns:mapy>162</tns:mapy><tns:congestionLocation><tns:name>Harbour Bridge</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Stafford Rd - Esmonde Rd</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>215</tns:id><tns:name>SH1 Alpurt Web cam</tns:name><tns:description>Johnstone hill tunnels looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/215.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/215</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>212</tns:id><tns:name>SH1 17 Goodwood</tns:name><tns:description>Goodwood heights looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/212.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/212</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>214</tns:id><tns:name>SH1 18 Rainbows End</tns:name><tns:description>Rainbows End looking north at SH1 and SH20 link</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/214.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/214</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>60</tns:id><tns:name>SH1 1 CMJ</tns:name><tns:description>Central motorway junction looking south at the link between state highways 1 and 16</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/60.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/60</tns:viewUrl><tns:mapx>162</tns:mapx><tns:mapy>217</tns:mapy><tns:congestionLocation><tns:name>Nelson St - Gillies Ave</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>70</tns:id><tns:name>SH1 2 Market Rd</tns:name><tns:description>Southern motorway at newmarket looking south towards the Market  Rd overbridge</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/70.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/70</tns:viewUrl><tns:mapx>183</tns:mapx><tns:mapy>241</tns:mapy><tns:congestionLocation><tns:name>Gillies Ave - Greenlane</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Greenlane - Gillies Ave</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>80</tns:id><tns:name>SH1 3 Greenlane Rd</tns:name><tns:description>Greenlane Rd looking north</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/80.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/80</tns:viewUrl><tns:mapx>198</tns:mapx><tns:mapy>262</tns:mapy><tns:congestionLocation><tns:name>Gillies Ave - Greenlane</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Greenlane - Gillies Ave</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>90</tns:id><tns:name>SH1 4 SE Highway</tns:name><tns:description>South eastern highway looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/90.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/90</tns:viewUrl><tns:mapx>219</tns:mapx><tns:mapy>278</tns:mapy><tns:congestionLocation><tns:name>Mt Wellington Hway - SE Highway</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>SE Highway - Mt Wellington Hway</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Moderate</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>100</tns:id><tns:name>SH1 5 Redoubt Rd</tns:name><tns:description>Redoubt Rd looking north</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/100.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/100</tns:viewUrl><tns:mapx>254</tns:mapx><tns:mapy>341</tns:mapy><tns:congestionLocation><tns:name>Redoubt Rd - Hill Rd</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Hill Rd - Redoubt Rd</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>110</tns:id><tns:name>SH1 6 Bairds Rd</tns:name><tns:description>Bairds Rd looking north</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/110.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/110</tns:viewUrl><tns:mapx>275</tns:mapx><tns:mapy>383</tns:mapy><tns:congestionLocation><tns:name>East Tamaki Rd - Princes St</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Princes St - East Tamaki Rd</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>120</tns:id><tns:name>SH1 7 Alfriston Rd</tns:name><tns:description>Alfriston Rd looking north</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/120.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/120</tns:viewUrl><tns:mapx>291</tns:mapx><tns:mapy>411</tns:mapy><tns:congestionLocation><tns:name>Takanini - Hill Rd</tns:name><tns:direction>Northbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation><tns:congestionLocation><tns:name>Hill Rd - Takanini</tns:name><tns:direction>Southbound</tns:direction><tns:congestion>Free Flow</tns:congestion></tns:congestionLocation></tns:camera><tns:camera><tns:id>121</tns:id><tns:name>SH1 8 Takanini</tns:name><tns:description>Takanini looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/121.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/121</tns:viewUrl><tns:mapx>290</tns:mapx><tns:mapy>380</tns:mapy></tns:camera><tns:camera><tns:id>122</tns:id><tns:name>SH1 9 Walter Streven</tns:name><tns:description>Walter-Strevens Drive looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/122.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/122</tns:viewUrl><tns:mapx>285</tns:mapx><tns:mapy>400</tns:mapy></tns:camera><tns:camera><tns:id>123</tns:id><tns:name>SH1 10 Pahurehure</tns:name><tns:description>Pahurehure looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/123.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/123</tns:viewUrl><tns:mapx>265</tns:mapx><tns:mapy>410</tns:mapy></tns:camera><tns:camera><tns:id>124</tns:id><tns:name>SH1 11 Rushgreen Ave</tns:name><tns:description>Rushgreen Ave looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/124.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/124</tns:viewUrl><tns:mapx>285</tns:mapx><tns:mapy>420</tns:mapy></tns:camera><tns:camera><tns:id>125</tns:id><tns:name>SH1 12 Park Estate</tns:name><tns:description>Park estate looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/125.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/125</tns:viewUrl><tns:mapx>300</tns:mapx><tns:mapy>430</tns:mapy></tns:camera><tns:camera><tns:id>126</tns:id><tns:name>SH1 13 Slippery Crk</tns:name><tns:description>Slippery Creek looking  south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/126.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/126</tns:viewUrl><tns:mapx>286</tns:mapx><tns:mapy>445</tns:mapy></tns:camera><tns:camera><tns:id>274</tns:id><tns:name>SH20A Montgomerie Rd</tns:name><tns:description>Montgomerie Rd looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/274.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/274</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>275</tns:id><tns:name>SH20A Kirkbride Road</tns:name><tns:description>Kirkbride Rd looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/275.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/275</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>276</tns:id><tns:name>SH20A Bader Drive</tns:name><tns:description>Bader Drive looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/276.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/276</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>272</tns:id><tns:name>SH20B Prices Road</tns:name><tns:description>Prices Rd looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/272.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/272</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>273</tns:id><tns:name>SH20B Waokauri Creek</tns:name><tns:description>Waokauri Creek looking west</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/273.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/273</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>190</tns:id><tns:name>SH20 1 Queenstown Rd</tns:name><tns:description>Queenstown Rd looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/190.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/190</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>191</tns:id><tns:name>SH20 2 Hillsborough</tns:name><tns:description>Hillsborough Rd looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/191.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/191</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>192</tns:id><tns:name>SH20 3 Melrose</tns:name><tns:description>Melrose looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/192.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/192</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>193</tns:id><tns:name>SH20 4 Dominion Rd</tns:name><tns:description>Dominion Rd looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/193.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/193</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>194</tns:id><tns:name>SH20 5 Sandringham</tns:name><tns:description>Sandringham looking South</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/194.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/194</tns:viewUrl><tns:mapx>35</tns:mapx><tns:mapy>207</tns:mapy></tns:camera><tns:camera><tns:id>201</tns:id><tns:name>SH20 6 Gloucester Pk</tns:name><tns:description>Gloucester Park looking north</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/201.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/201</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>202</tns:id><tns:name>SH20 7 Onehunga</tns:name><tns:description>Onehunga wharf looking north</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/202.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/202</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>203</tns:id><tns:name>SH20 8 Rimu Rd</tns:name><tns:description>Rimu Rd looking north</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/203.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/203</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>204</tns:id><tns:name>SH20 9 Crawford Ave</tns:name><tns:description>Crawford Ave looking north</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/204.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/204</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>205</tns:id><tns:name>SH20 Coronation Rd</tns:name><tns:description>Coronation Rd looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/205.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/205</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>206</tns:id><tns:name>SH20 11 Puhinui Rd</tns:name><tns:description>Puhinui road interchange looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/206.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/206</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>207</tns:id><tns:name>SH20 12 Nesdale Road</tns:name><tns:description>Nesdale Rd looking east</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/207.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/207</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>208</tns:id><tns:name>SH20 13 Plunket Ave</tns:name><tns:description>Plunket Ave looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/208.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/208</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>209</tns:id><tns:name>SH20 14 Lambie Drive</tns:name><tns:description>Lambie Drive looking south</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/209.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/209</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>210</tns:id><tns:name>SH20 15 Barrowcliffe</tns:name><tns:description>Barrowcliffe Place looking west</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/210.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/210</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera><tns:camera><tns:id>211</tns:id><tns:name>SH20 16 Great South</tns:name><tns:description>Great South Rd Looking westbound</tns:description><tns:offline>false</tns:offline><tns:underMaintenance>false</tns:underMaintenance><tns:imageUrl>http://www.trafficnz.info/camera/211.jpg</tns:imageUrl><tns:viewUrl>http://www.trafficnz.info/camera/view/211</tns:viewUrl><tns:mapx>0</tns:mapx><tns:mapy>0</tns:mapy></tns:camera></tns:getCamerasResponse>')

In [5]:
oplinz = open('linkz', 'r')

In [10]:
datadict = xmltodict.parse(thexml)

In [11]:
import geopy
geoloc = geopy.geocoders.GoogleV3()

In [12]:
import json

#write the dictionary to a file
outfile = open('linkz', 'w')
json.dump(datadict, outfile)

#read the data back in
with open('linkz') as infile:
    newDictionary = json.load(infile)

In [13]:
althere = newDictionary[u'tns:getCamerasResponse']
bthere = althere[u'tns:camera']

In [14]:
neth = len(bthere)

In [15]:
print neth


62

In [16]:
import random

In [17]:
theimgz = random.randint(0,neth)

In [23]:
bth = bthere[4]

In [53]:
def returndata(self):
    for self in range(neth):
        print bthere[self]
        print bthere[0]['tns:imageUrl']

In [ ]:
def checkself(self):

In [54]:
bthere[0]['tns:imageUrl']


Out[54]:
u'http://www.trafficnz.info/camera/130.jpg'

In [56]:
returndata(6)


{u'tns:id': u'130', u'tns:imageUrl': u'http://www.trafficnz.info/camera/130.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/130', u'tns:description': u'Bond St looking east', u'tns:mapx': u'142', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'St Lukes Rd - Newton Rd', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Newton Rd - St Lukes Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'229', u'tns:name': u'SH16 1 Bond St'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'140', u'tns:imageUrl': u'http://www.trafficnz.info/camera/140.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/140', u'tns:description': u'Gt North Road looking west', u'tns:mapx': u'113', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Rosebank Rd - Great Nth Rd Waterview', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Great Nth Rd Waterview - Rosebank Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'232', u'tns:name': u'SH16 2 Gt North Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'150', u'tns:imageUrl': u'http://www.trafficnz.info/camera/150.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/150', u'tns:description': u'Te Atatu Road looking east', u'tns:mapx': u'70', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Te Atatu Rd - Rosebank Rd', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Rosebank Rd - Te Atatu Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'216', u'tns:name': u'SH16 3 Te Atatu Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'160', u'tns:imageUrl': u'http://www.trafficnz.info/camera/160.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/160', u'tns:description': u'Lincoln Rd  looking west', u'tns:mapx': u'52', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Te Atatu Rd - Lincoln Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Lincoln Rd - Te Atatu Rd', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'207', u'tns:name': u'SH16 4 Lincoln Rd E'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'170', u'tns:imageUrl': u'http://www.trafficnz.info/camera/170.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/170', u'tns:description': u'Lincoln Rd looking east', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Lincoln Rd - Royal Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Royal Rd - Lincoln Rd', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'207', u'tns:name': u'SH16 5 Lincoln Rd W'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'270', u'tns:imageUrl': u'http://www.trafficnz.info/camera/270.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/270', u'tns:description': u'Hobsonville looking West towards Kumeu', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH16 6 Hobsonville W'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'271', u'tns:imageUrl': u'http://www.trafficnz.info/camera/271.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/271', u'tns:description': u'Hobsonville Road looking East', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH16 7 Hobsonville E'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'221', u'tns:imageUrl': u'http://www.trafficnz.info/camera/221.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/221', u'tns:description': u'Trig Rd looking west', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH18 Trig Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'222', u'tns:imageUrl': u'http://www.trafficnz.info/camera/222.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/222', u'tns:description': u'Upper harbour motorway looking west', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH18 Waiahora Creek'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'223', u'tns:imageUrl': u'http://www.trafficnz.info/camera/223.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/223', u'tns:description': u'Upper harbour motorway looking East', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH18 Brigham Creek'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'224', u'tns:imageUrl': u'http://www.trafficnz.info/camera/224.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/224', u'tns:description': u'Upper harbour motorway looking west', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH18 Sinton Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'225', u'tns:imageUrl': u'http://www.trafficnz.info/camera/225.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/225', u'tns:description': u'Upper harbour motorway looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH18 Squadron Dr'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'171', u'tns:imageUrl': u'http://www.trafficnz.info/camera/171.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/171', u'tns:description': u'Tauhinu bridge looking east', u'tns:mapx': u'60', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 6 Tauhinu BRG'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'172', u'tns:imageUrl': u'http://www.trafficnz.info/camera/172.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/172', u'tns:description': u'Albany Highway Looking East', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 7 Albany HWY'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'173', u'tns:imageUrl': u'http://www.trafficnz.info/camera/173.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/173', u'tns:description': u'Tauhinu East Looking East', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 8 Tauhinu East'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'174', u'tns:imageUrl': u'http://www.trafficnz.info/camera/174.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/174', u'tns:description': u'Paul matthews looking east', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 9 Paul Matthews'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'175', u'tns:imageUrl': u'http://www.trafficnz.info/camera/175.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/175', u'tns:description': u'Greenhithe Rd looking east', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 10 Greenhithe'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'176', u'tns:imageUrl': u'http://www.trafficnz.info/camera/176.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/176', u'tns:description': u'George deane looking east', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 11 George Deane'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'177', u'tns:imageUrl': u'http://www.trafficnz.info/camera/177.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/177', u'tns:description': u'Upper harbour looking east', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 12 Upper Hbr CW'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'178', u'tns:imageUrl': u'http://www.trafficnz.info/camera/178.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/178', u'tns:description': u'Wicklam Lane looking west', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 13 Wicklam Lane'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'10', u'tns:imageUrl': u'http://www.trafficnz.info/camera/10.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/10', u'tns:description': u'Greville road looking south', u'tns:mapx': u'125', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Upper Harb Hwy - Oteha Valley Rd', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Oteha Valley Rd - Upper Harb Hwy', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'71', u'tns:name': u'SH1 1 Greville Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'20', u'tns:imageUrl': u'http://www.trafficnz.info/camera/20.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/20', u'tns:description': u'Tristram Avenue looking south', u'tns:mapx': u'148', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Tristram Ave - Esmonde Rd', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Esmonde Rd - Tristram Ave', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'118', u'tns:name': u'SH1 2 Tristram Ave'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'30', u'tns:imageUrl': u'http://www.trafficnz.info/camera/30.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/30', u'tns:description': u'Northcote Rd looking north', u'tns:mapx': u'156', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Tristram Ave - Esmonde Rd', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Esmonde Rd - Tristram Ave', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'141', u'tns:name': u'SH1 3 Northcote Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'40', u'tns:imageUrl': u'http://www.trafficnz.info/camera/40.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/40', u'tns:description': u'Esmonde Rd looking south', u'tns:mapx': u'178', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Esmonde Rd - Onewa', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Stafford Rd - Esmonde Rd', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'146', u'tns:name': u'SH1 4 Esmonde Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'50', u'tns:imageUrl': u'http://www.trafficnz.info/camera/50.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/50', u'tns:description': u'Onewa Rd looking south', u'tns:mapx': u'157', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Harbour Bridge', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Stafford Rd - Esmonde Rd', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'162', u'tns:name': u'SH1 5 Onewa Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'215', u'tns:imageUrl': u'http://www.trafficnz.info/camera/215.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/215', u'tns:description': u'Johnstone hill tunnels looking south', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH1 Alpurt Web cam'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'212', u'tns:imageUrl': u'http://www.trafficnz.info/camera/212.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/212', u'tns:description': u'Goodwood heights looking south', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH1 17 Goodwood'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'214', u'tns:imageUrl': u'http://www.trafficnz.info/camera/214.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/214', u'tns:description': u'Rainbows End looking north at SH1 and SH20 link', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH1 18 Rainbows End'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'60', u'tns:imageUrl': u'http://www.trafficnz.info/camera/60.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/60', u'tns:description': u'Central motorway junction looking south at the link between state highways 1 and 16', u'tns:mapx': u'162', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': {u'tns:name': u'Nelson St - Gillies Ave', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, u'tns:mapy': u'217', u'tns:name': u'SH1 1 CMJ'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'70', u'tns:imageUrl': u'http://www.trafficnz.info/camera/70.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/70', u'tns:description': u'Southern motorway at newmarket looking south towards the Market  Rd overbridge', u'tns:mapx': u'183', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Gillies Ave - Greenlane', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Greenlane - Gillies Ave', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'241', u'tns:name': u'SH1 2 Market Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'80', u'tns:imageUrl': u'http://www.trafficnz.info/camera/80.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/80', u'tns:description': u'Greenlane Rd looking north', u'tns:mapx': u'198', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Gillies Ave - Greenlane', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Greenlane - Gillies Ave', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'262', u'tns:name': u'SH1 3 Greenlane Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'90', u'tns:imageUrl': u'http://www.trafficnz.info/camera/90.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/90', u'tns:description': u'South eastern highway looking south', u'tns:mapx': u'219', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Mt Wellington Hway - SE Highway', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'SE Highway - Mt Wellington Hway', u'tns:direction': u'Southbound', u'tns:congestion': u'Moderate'}], u'tns:mapy': u'278', u'tns:name': u'SH1 4 SE Highway'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'100', u'tns:imageUrl': u'http://www.trafficnz.info/camera/100.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/100', u'tns:description': u'Redoubt Rd looking north', u'tns:mapx': u'254', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Redoubt Rd - Hill Rd', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Hill Rd - Redoubt Rd', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'341', u'tns:name': u'SH1 5 Redoubt Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'110', u'tns:imageUrl': u'http://www.trafficnz.info/camera/110.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/110', u'tns:description': u'Bairds Rd looking north', u'tns:mapx': u'275', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'East Tamaki Rd - Princes St', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Princes St - East Tamaki Rd', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'383', u'tns:name': u'SH1 6 Bairds Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'120', u'tns:imageUrl': u'http://www.trafficnz.info/camera/120.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/120', u'tns:description': u'Alfriston Rd looking north', u'tns:mapx': u'291', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Takanini - Hill Rd', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Hill Rd - Takanini', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'411', u'tns:name': u'SH1 7 Alfriston Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'121', u'tns:imageUrl': u'http://www.trafficnz.info/camera/121.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/121', u'tns:description': u'Takanini looking south', u'tns:mapx': u'290', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'380', u'tns:name': u'SH1 8 Takanini'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'122', u'tns:imageUrl': u'http://www.trafficnz.info/camera/122.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/122', u'tns:description': u'Walter-Strevens Drive looking south', u'tns:mapx': u'285', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'400', u'tns:name': u'SH1 9 Walter Streven'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'123', u'tns:imageUrl': u'http://www.trafficnz.info/camera/123.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/123', u'tns:description': u'Pahurehure looking south', u'tns:mapx': u'265', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'410', u'tns:name': u'SH1 10 Pahurehure'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'124', u'tns:imageUrl': u'http://www.trafficnz.info/camera/124.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/124', u'tns:description': u'Rushgreen Ave looking south', u'tns:mapx': u'285', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'420', u'tns:name': u'SH1 11 Rushgreen Ave'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'125', u'tns:imageUrl': u'http://www.trafficnz.info/camera/125.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/125', u'tns:description': u'Park estate looking south', u'tns:mapx': u'300', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'430', u'tns:name': u'SH1 12 Park Estate'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'126', u'tns:imageUrl': u'http://www.trafficnz.info/camera/126.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/126', u'tns:description': u'Slippery Creek looking  south', u'tns:mapx': u'286', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'445', u'tns:name': u'SH1 13 Slippery Crk'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'274', u'tns:imageUrl': u'http://www.trafficnz.info/camera/274.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/274', u'tns:description': u'Montgomerie Rd looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20A Montgomerie Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'275', u'tns:imageUrl': u'http://www.trafficnz.info/camera/275.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/275', u'tns:description': u'Kirkbride Rd looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20A Kirkbride Road'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'276', u'tns:imageUrl': u'http://www.trafficnz.info/camera/276.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/276', u'tns:description': u'Bader Drive looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20A Bader Drive'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'272', u'tns:imageUrl': u'http://www.trafficnz.info/camera/272.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/272', u'tns:description': u'Prices Rd looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20B Prices Road'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'273', u'tns:imageUrl': u'http://www.trafficnz.info/camera/273.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/273', u'tns:description': u'Waokauri Creek looking west', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20B Waokauri Creek'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'190', u'tns:imageUrl': u'http://www.trafficnz.info/camera/190.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/190', u'tns:description': u'Queenstown Rd looking south', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH20 1 Queenstown Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'191', u'tns:imageUrl': u'http://www.trafficnz.info/camera/191.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/191', u'tns:description': u'Hillsborough Rd looking south', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH20 2 Hillsborough'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'192', u'tns:imageUrl': u'http://www.trafficnz.info/camera/192.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/192', u'tns:description': u'Melrose looking south', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH20 3 Melrose'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'193', u'tns:imageUrl': u'http://www.trafficnz.info/camera/193.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/193', u'tns:description': u'Dominion Rd looking south', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH20 4 Dominion Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'194', u'tns:imageUrl': u'http://www.trafficnz.info/camera/194.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/194', u'tns:description': u'Sandringham looking South', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH20 5 Sandringham'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'201', u'tns:imageUrl': u'http://www.trafficnz.info/camera/201.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/201', u'tns:description': u'Gloucester Park looking north', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 6 Gloucester Pk'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'202', u'tns:imageUrl': u'http://www.trafficnz.info/camera/202.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/202', u'tns:description': u'Onehunga wharf looking north', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 7 Onehunga'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'203', u'tns:imageUrl': u'http://www.trafficnz.info/camera/203.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/203', u'tns:description': u'Rimu Rd looking north', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 8 Rimu Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'204', u'tns:imageUrl': u'http://www.trafficnz.info/camera/204.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/204', u'tns:description': u'Crawford Ave looking north', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 9 Crawford Ave'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'205', u'tns:imageUrl': u'http://www.trafficnz.info/camera/205.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/205', u'tns:description': u'Coronation Rd looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 Coronation Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'206', u'tns:imageUrl': u'http://www.trafficnz.info/camera/206.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/206', u'tns:description': u'Puhinui road interchange looking south', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 11 Puhinui Rd'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'207', u'tns:imageUrl': u'http://www.trafficnz.info/camera/207.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/207', u'tns:description': u'Nesdale Rd looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 12 Nesdale Road'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'208', u'tns:imageUrl': u'http://www.trafficnz.info/camera/208.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/208', u'tns:description': u'Plunket Ave looking south', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 13 Plunket Ave'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'209', u'tns:imageUrl': u'http://www.trafficnz.info/camera/209.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/209', u'tns:description': u'Lambie Drive looking south', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 14 Lambie Drive'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'210', u'tns:imageUrl': u'http://www.trafficnz.info/camera/210.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/210', u'tns:description': u'Barrowcliffe Place looking west', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 15 Barrowcliffe'}
http://www.trafficnz.info/camera/130.jpg
{u'tns:id': u'211', u'tns:imageUrl': u'http://www.trafficnz.info/camera/211.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/211', u'tns:description': u'Great South Rd Looking westbound', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 16 Great South'}
http://www.trafficnz.info/camera/130.jpg

In [33]:
for bea in range(neth):
    print bthere[bea]


{u'tns:id': u'130', u'tns:imageUrl': u'http://www.trafficnz.info/camera/130.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/130', u'tns:description': u'Bond St looking east', u'tns:mapx': u'142', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'St Lukes Rd - Newton Rd', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Newton Rd - St Lukes Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'229', u'tns:name': u'SH16 1 Bond St'}
{u'tns:id': u'140', u'tns:imageUrl': u'http://www.trafficnz.info/camera/140.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/140', u'tns:description': u'Gt North Road looking west', u'tns:mapx': u'113', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Rosebank Rd - Great Nth Rd Waterview', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Great Nth Rd Waterview - Rosebank Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'232', u'tns:name': u'SH16 2 Gt North Rd'}
{u'tns:id': u'150', u'tns:imageUrl': u'http://www.trafficnz.info/camera/150.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/150', u'tns:description': u'Te Atatu Road looking east', u'tns:mapx': u'70', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Te Atatu Rd - Rosebank Rd', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Rosebank Rd - Te Atatu Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'216', u'tns:name': u'SH16 3 Te Atatu Rd'}
{u'tns:id': u'160', u'tns:imageUrl': u'http://www.trafficnz.info/camera/160.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/160', u'tns:description': u'Lincoln Rd  looking west', u'tns:mapx': u'52', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Te Atatu Rd - Lincoln Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Lincoln Rd - Te Atatu Rd', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'207', u'tns:name': u'SH16 4 Lincoln Rd E'}
{u'tns:id': u'170', u'tns:imageUrl': u'http://www.trafficnz.info/camera/170.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/170', u'tns:description': u'Lincoln Rd looking east', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Lincoln Rd - Royal Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Royal Rd - Lincoln Rd', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'207', u'tns:name': u'SH16 5 Lincoln Rd W'}
{u'tns:id': u'270', u'tns:imageUrl': u'http://www.trafficnz.info/camera/270.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/270', u'tns:description': u'Hobsonville looking West towards Kumeu', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH16 6 Hobsonville W'}
{u'tns:id': u'271', u'tns:imageUrl': u'http://www.trafficnz.info/camera/271.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/271', u'tns:description': u'Hobsonville Road looking East', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH16 7 Hobsonville E'}
{u'tns:id': u'221', u'tns:imageUrl': u'http://www.trafficnz.info/camera/221.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/221', u'tns:description': u'Trig Rd looking west', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH18 Trig Rd'}
{u'tns:id': u'222', u'tns:imageUrl': u'http://www.trafficnz.info/camera/222.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/222', u'tns:description': u'Upper harbour motorway looking west', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH18 Waiahora Creek'}
{u'tns:id': u'223', u'tns:imageUrl': u'http://www.trafficnz.info/camera/223.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/223', u'tns:description': u'Upper harbour motorway looking East', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH18 Brigham Creek'}
{u'tns:id': u'224', u'tns:imageUrl': u'http://www.trafficnz.info/camera/224.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/224', u'tns:description': u'Upper harbour motorway looking west', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH18 Sinton Rd'}
{u'tns:id': u'225', u'tns:imageUrl': u'http://www.trafficnz.info/camera/225.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/225', u'tns:description': u'Upper harbour motorway looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH18 Squadron Dr'}
{u'tns:id': u'171', u'tns:imageUrl': u'http://www.trafficnz.info/camera/171.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/171', u'tns:description': u'Tauhinu bridge looking east', u'tns:mapx': u'60', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 6 Tauhinu BRG'}
{u'tns:id': u'172', u'tns:imageUrl': u'http://www.trafficnz.info/camera/172.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/172', u'tns:description': u'Albany Highway Looking East', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 7 Albany HWY'}
{u'tns:id': u'173', u'tns:imageUrl': u'http://www.trafficnz.info/camera/173.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/173', u'tns:description': u'Tauhinu East Looking East', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 8 Tauhinu East'}
{u'tns:id': u'174', u'tns:imageUrl': u'http://www.trafficnz.info/camera/174.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/174', u'tns:description': u'Paul matthews looking east', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 9 Paul Matthews'}
{u'tns:id': u'175', u'tns:imageUrl': u'http://www.trafficnz.info/camera/175.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/175', u'tns:description': u'Greenhithe Rd looking east', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 10 Greenhithe'}
{u'tns:id': u'176', u'tns:imageUrl': u'http://www.trafficnz.info/camera/176.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/176', u'tns:description': u'George deane looking east', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 11 George Deane'}
{u'tns:id': u'177', u'tns:imageUrl': u'http://www.trafficnz.info/camera/177.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/177', u'tns:description': u'Upper harbour looking east', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 12 Upper Hbr CW'}
{u'tns:id': u'178', u'tns:imageUrl': u'http://www.trafficnz.info/camera/178.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/178', u'tns:description': u'Wicklam Lane looking west', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH18 13 Wicklam Lane'}
{u'tns:id': u'10', u'tns:imageUrl': u'http://www.trafficnz.info/camera/10.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/10', u'tns:description': u'Greville road looking south', u'tns:mapx': u'125', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Upper Harb Hwy - Oteha Valley Rd', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Oteha Valley Rd - Upper Harb Hwy', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'71', u'tns:name': u'SH1 1 Greville Rd'}
{u'tns:id': u'20', u'tns:imageUrl': u'http://www.trafficnz.info/camera/20.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/20', u'tns:description': u'Tristram Avenue looking south', u'tns:mapx': u'148', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Tristram Ave - Esmonde Rd', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Esmonde Rd - Tristram Ave', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'118', u'tns:name': u'SH1 2 Tristram Ave'}
{u'tns:id': u'30', u'tns:imageUrl': u'http://www.trafficnz.info/camera/30.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/30', u'tns:description': u'Northcote Rd looking north', u'tns:mapx': u'156', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Tristram Ave - Esmonde Rd', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Esmonde Rd - Tristram Ave', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'141', u'tns:name': u'SH1 3 Northcote Rd'}
{u'tns:id': u'40', u'tns:imageUrl': u'http://www.trafficnz.info/camera/40.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/40', u'tns:description': u'Esmonde Rd looking south', u'tns:mapx': u'178', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Esmonde Rd - Onewa', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Stafford Rd - Esmonde Rd', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'146', u'tns:name': u'SH1 4 Esmonde Rd'}
{u'tns:id': u'50', u'tns:imageUrl': u'http://www.trafficnz.info/camera/50.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/50', u'tns:description': u'Onewa Rd looking south', u'tns:mapx': u'157', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Harbour Bridge', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Stafford Rd - Esmonde Rd', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'162', u'tns:name': u'SH1 5 Onewa Rd'}
{u'tns:id': u'215', u'tns:imageUrl': u'http://www.trafficnz.info/camera/215.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/215', u'tns:description': u'Johnstone hill tunnels looking south', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH1 Alpurt Web cam'}
{u'tns:id': u'212', u'tns:imageUrl': u'http://www.trafficnz.info/camera/212.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/212', u'tns:description': u'Goodwood heights looking south', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH1 17 Goodwood'}
{u'tns:id': u'214', u'tns:imageUrl': u'http://www.trafficnz.info/camera/214.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/214', u'tns:description': u'Rainbows End looking north at SH1 and SH20 link', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH1 18 Rainbows End'}
{u'tns:id': u'60', u'tns:imageUrl': u'http://www.trafficnz.info/camera/60.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/60', u'tns:description': u'Central motorway junction looking south at the link between state highways 1 and 16', u'tns:mapx': u'162', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': {u'tns:name': u'Nelson St - Gillies Ave', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, u'tns:mapy': u'217', u'tns:name': u'SH1 1 CMJ'}
{u'tns:id': u'70', u'tns:imageUrl': u'http://www.trafficnz.info/camera/70.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/70', u'tns:description': u'Southern motorway at newmarket looking south towards the Market  Rd overbridge', u'tns:mapx': u'183', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Gillies Ave - Greenlane', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Greenlane - Gillies Ave', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'241', u'tns:name': u'SH1 2 Market Rd'}
{u'tns:id': u'80', u'tns:imageUrl': u'http://www.trafficnz.info/camera/80.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/80', u'tns:description': u'Greenlane Rd looking north', u'tns:mapx': u'198', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Gillies Ave - Greenlane', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Greenlane - Gillies Ave', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'262', u'tns:name': u'SH1 3 Greenlane Rd'}
{u'tns:id': u'90', u'tns:imageUrl': u'http://www.trafficnz.info/camera/90.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/90', u'tns:description': u'South eastern highway looking south', u'tns:mapx': u'219', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Mt Wellington Hway - SE Highway', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'SE Highway - Mt Wellington Hway', u'tns:direction': u'Southbound', u'tns:congestion': u'Moderate'}], u'tns:mapy': u'278', u'tns:name': u'SH1 4 SE Highway'}
{u'tns:id': u'100', u'tns:imageUrl': u'http://www.trafficnz.info/camera/100.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/100', u'tns:description': u'Redoubt Rd looking north', u'tns:mapx': u'254', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Redoubt Rd - Hill Rd', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Hill Rd - Redoubt Rd', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'341', u'tns:name': u'SH1 5 Redoubt Rd'}
{u'tns:id': u'110', u'tns:imageUrl': u'http://www.trafficnz.info/camera/110.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/110', u'tns:description': u'Bairds Rd looking north', u'tns:mapx': u'275', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'East Tamaki Rd - Princes St', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Princes St - East Tamaki Rd', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'383', u'tns:name': u'SH1 6 Bairds Rd'}
{u'tns:id': u'120', u'tns:imageUrl': u'http://www.trafficnz.info/camera/120.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/120', u'tns:description': u'Alfriston Rd looking north', u'tns:mapx': u'291', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:congestionLocation': [{u'tns:name': u'Takanini - Hill Rd', u'tns:direction': u'Northbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Hill Rd - Takanini', u'tns:direction': u'Southbound', u'tns:congestion': u'Free Flow'}], u'tns:mapy': u'411', u'tns:name': u'SH1 7 Alfriston Rd'}
{u'tns:id': u'121', u'tns:imageUrl': u'http://www.trafficnz.info/camera/121.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/121', u'tns:description': u'Takanini looking south', u'tns:mapx': u'290', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'380', u'tns:name': u'SH1 8 Takanini'}
{u'tns:id': u'122', u'tns:imageUrl': u'http://www.trafficnz.info/camera/122.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/122', u'tns:description': u'Walter-Strevens Drive looking south', u'tns:mapx': u'285', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'400', u'tns:name': u'SH1 9 Walter Streven'}
{u'tns:id': u'123', u'tns:imageUrl': u'http://www.trafficnz.info/camera/123.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/123', u'tns:description': u'Pahurehure looking south', u'tns:mapx': u'265', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'410', u'tns:name': u'SH1 10 Pahurehure'}
{u'tns:id': u'124', u'tns:imageUrl': u'http://www.trafficnz.info/camera/124.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/124', u'tns:description': u'Rushgreen Ave looking south', u'tns:mapx': u'285', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'420', u'tns:name': u'SH1 11 Rushgreen Ave'}
{u'tns:id': u'125', u'tns:imageUrl': u'http://www.trafficnz.info/camera/125.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/125', u'tns:description': u'Park estate looking south', u'tns:mapx': u'300', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'430', u'tns:name': u'SH1 12 Park Estate'}
{u'tns:id': u'126', u'tns:imageUrl': u'http://www.trafficnz.info/camera/126.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/126', u'tns:description': u'Slippery Creek looking  south', u'tns:mapx': u'286', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'445', u'tns:name': u'SH1 13 Slippery Crk'}
{u'tns:id': u'274', u'tns:imageUrl': u'http://www.trafficnz.info/camera/274.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/274', u'tns:description': u'Montgomerie Rd looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20A Montgomerie Rd'}
{u'tns:id': u'275', u'tns:imageUrl': u'http://www.trafficnz.info/camera/275.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/275', u'tns:description': u'Kirkbride Rd looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20A Kirkbride Road'}
{u'tns:id': u'276', u'tns:imageUrl': u'http://www.trafficnz.info/camera/276.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/276', u'tns:description': u'Bader Drive looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20A Bader Drive'}
{u'tns:id': u'272', u'tns:imageUrl': u'http://www.trafficnz.info/camera/272.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/272', u'tns:description': u'Prices Rd looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20B Prices Road'}
{u'tns:id': u'273', u'tns:imageUrl': u'http://www.trafficnz.info/camera/273.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/273', u'tns:description': u'Waokauri Creek looking west', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20B Waokauri Creek'}
{u'tns:id': u'190', u'tns:imageUrl': u'http://www.trafficnz.info/camera/190.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/190', u'tns:description': u'Queenstown Rd looking south', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH20 1 Queenstown Rd'}
{u'tns:id': u'191', u'tns:imageUrl': u'http://www.trafficnz.info/camera/191.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/191', u'tns:description': u'Hillsborough Rd looking south', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH20 2 Hillsborough'}
{u'tns:id': u'192', u'tns:imageUrl': u'http://www.trafficnz.info/camera/192.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/192', u'tns:description': u'Melrose looking south', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH20 3 Melrose'}
{u'tns:id': u'193', u'tns:imageUrl': u'http://www.trafficnz.info/camera/193.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/193', u'tns:description': u'Dominion Rd looking south', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH20 4 Dominion Rd'}
{u'tns:id': u'194', u'tns:imageUrl': u'http://www.trafficnz.info/camera/194.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/194', u'tns:description': u'Sandringham looking South', u'tns:mapx': u'35', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'207', u'tns:name': u'SH20 5 Sandringham'}
{u'tns:id': u'201', u'tns:imageUrl': u'http://www.trafficnz.info/camera/201.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/201', u'tns:description': u'Gloucester Park looking north', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 6 Gloucester Pk'}
{u'tns:id': u'202', u'tns:imageUrl': u'http://www.trafficnz.info/camera/202.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/202', u'tns:description': u'Onehunga wharf looking north', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 7 Onehunga'}
{u'tns:id': u'203', u'tns:imageUrl': u'http://www.trafficnz.info/camera/203.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/203', u'tns:description': u'Rimu Rd looking north', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 8 Rimu Rd'}
{u'tns:id': u'204', u'tns:imageUrl': u'http://www.trafficnz.info/camera/204.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/204', u'tns:description': u'Crawford Ave looking north', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 9 Crawford Ave'}
{u'tns:id': u'205', u'tns:imageUrl': u'http://www.trafficnz.info/camera/205.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/205', u'tns:description': u'Coronation Rd looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 Coronation Rd'}
{u'tns:id': u'206', u'tns:imageUrl': u'http://www.trafficnz.info/camera/206.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/206', u'tns:description': u'Puhinui road interchange looking south', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 11 Puhinui Rd'}
{u'tns:id': u'207', u'tns:imageUrl': u'http://www.trafficnz.info/camera/207.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/207', u'tns:description': u'Nesdale Rd looking east', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 12 Nesdale Road'}
{u'tns:id': u'208', u'tns:imageUrl': u'http://www.trafficnz.info/camera/208.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/208', u'tns:description': u'Plunket Ave looking south', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 13 Plunket Ave'}
{u'tns:id': u'209', u'tns:imageUrl': u'http://www.trafficnz.info/camera/209.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/209', u'tns:description': u'Lambie Drive looking south', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 14 Lambie Drive'}
{u'tns:id': u'210', u'tns:imageUrl': u'http://www.trafficnz.info/camera/210.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/210', u'tns:description': u'Barrowcliffe Place looking west', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 15 Barrowcliffe'}
{u'tns:id': u'211', u'tns:imageUrl': u'http://www.trafficnz.info/camera/211.jpg', u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/211', u'tns:description': u'Great South Rd Looking westbound', u'tns:mapx': u'0', u'tns:offline': u'false', u'tns:underMaintenance': u'false', u'tns:mapy': u'0', u'tns:name': u'SH20 16 Great South'}

In [34]:
bthkey = bth.keys()

In [35]:
sindat = []

In [36]:
for kez in bthkey:
    #print kez
    print bth[kez]
    sindat.append(bth[kez])


170
http://www.trafficnz.info/camera/170.jpg
http://www.trafficnz.info/camera/view/170
Lincoln Rd looking east
35
false
false
[{u'tns:name': u'Lincoln Rd - Royal Rd', u'tns:direction': u'Westbound', u'tns:congestion': u'Free Flow'}, {u'tns:name': u'Royal Rd - Lincoln Rd', u'tns:direction': u'Eastbound', u'tns:congestion': u'Free Flow'}]
207
SH16 5 Lincoln Rd W

In [27]:
sindat


Out[27]:
[u'170',
 u'http://www.trafficnz.info/camera/170.jpg',
 u'http://www.trafficnz.info/camera/view/170',
 u'Lincoln Rd looking east',
 u'35',
 u'false',
 u'false',
 [{u'tns:congestion': u'Free Flow',
   u'tns:direction': u'Westbound',
   u'tns:name': u'Lincoln Rd - Royal Rd'},
  {u'tns:congestion': u'Free Flow',
   u'tns:direction': u'Eastbound',
   u'tns:name': u'Royal Rd - Lincoln Rd'}],
 u'207',
 u'SH16 5 Lincoln Rd W']

In [28]:
idnum = sindat[0]

In [29]:
print idnum


170

In [30]:
topz = stad[0]


---------------------------------------------------------------------------
NameError                                 Traceback (most recent call last)
<ipython-input-30-fc80c210302d> in <module>()
----> 1 topz = stad[0]

NameError: name 'stad' is not defined

In [31]:
snam = topz[0]


---------------------------------------------------------------------------
NameError                                 Traceback (most recent call last)
<ipython-input-31-af5dba46ecf1> in <module>()
----> 1 snam = topz[0]

NameError: name 'topz' is not defined

In [55]:
jpgcam = sindat[1]
numcam = sindat[0]
addyo = sindat[3]
addyi = sindat[8]
stad = sindat[7]

faddy = stad + ' new zealand'
jnacam = numcam + '.jpg'
print faddy


0 new zealand

In [56]:
stad[0]


Out[56]:
u'0'

In [57]:
address = geoloc.geocode(faddy)

In [58]:
print address


0

In [59]:
address.raw


Out[59]:
{u'address_components': [{u'long_name': u'0',
   u'short_name': u'0',
   u'types': []}],
 u'formatted_address': u'0',
 u'geometry': {u'bounds': {u'northeast': {u'lat': 52.9115348,
    u'lng': -1.5114183},
   u'southwest': {u'lat': 52.91032380000001, u'lng': -1.5139462}},
  u'location': {u'lat': 52.9109293, u'lng': -1.5126822},
  u'location_type': u'APPROXIMATE',
  u'viewport': {u'northeast': {u'lat': 52.9133171, u'lng': -1.5085839},
   u'southwest': {u'lat': 52.9075368, u'lng': -1.5191671}}},
 u'partial_match': True,
 u'types': []}

In [60]:
bthere[0]


Out[60]:
{u'tns:congestionLocation': [{u'tns:congestion': u'Free Flow',
   u'tns:direction': u'Eastbound',
   u'tns:name': u'St Lukes Rd - Newton Rd'},
  {u'tns:congestion': u'Free Flow',
   u'tns:direction': u'Westbound',
   u'tns:name': u'Newton Rd - St Lukes Rd'}],
 u'tns:description': u'Bond St looking east',
 u'tns:id': u'130',
 u'tns:imageUrl': u'http://www.trafficnz.info/camera/130.jpg',
 u'tns:mapx': u'142',
 u'tns:mapy': u'229',
 u'tns:name': u'SH16 1 Bond St',
 u'tns:offline': u'false',
 u'tns:underMaintenance': u'false',
 u'tns:viewUrl': u'http://www.trafficnz.info/camera/view/130'}

In [61]:
import requests

In [62]:
import os

In [63]:
os.chdir('/home/will/Desktop/highwaypiz')

In [64]:
with open(jnacam, 'wb') as handle:
    response = requests.get(jpgcam, stream=True)

    for block in response.iter_content(1024):
        if not block:
            break
        handle.write(block)

In [65]:
from IPython.display import Image 
    
Image(filename=jnacam)


Out[65]:

In [39]:
print jpgcam


http://www.trafficnz.info/camera/212.jpg

In [112]:
opstatic = requests.get('https://raw.githubusercontent.com/wcmckee/brobeur-static/master/index.html')

In [113]:
blehstat = opstatic.text

In [114]:
import BeautifulSoup

In [116]:
soupz = BeautifulSoup.BeautifulSoup(blehstat)

In [117]:
newta = soupz.a

In [118]:
newta


Out[118]:
<a href="/">BroBeur Studios</a>

In [141]:
soupz.img


Out[141]:
<img src="/imgs/bro.png" alt="brobeur" width="800" height="180" />

In [155]:
incimg = (jpgcam)

In [156]:
print incimg


http://www.trafficnz.info/camera/270.jpg

In [157]:
nsoup = soupz.prettify()

In [161]:
print soupz.img


<img src="/imgs/bro.png" alt="brobeur" width="800" height="180" />&lt;img src="http://www.trafficnz.info/camera/270.jpg" alt="Smiley face" width="250" height="200"&gt;

In [162]:
soupz.ul.append(incimg)

In [163]:
print nsoup


<!DOCTYPE html>
<html lang="en">
 <head>
  <meta charset="utf-8" />
  <title>
   BroBeur Studios
  </title>
  <link rel="stylesheet" href="/theme/css/main.css" />
  <link href="/feeds/all.atom.xml" type="application/atom+xml" rel="alternate" title="A Pelican Blog Atom Feed" />
  <!--[if IE]&gt;
            &lt;script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"&gt;&lt;/script&gt;
        &lt;![endif]-->
 </head>
 <body id="index" class="home">
  <header id="banner" class="body">
   <img src="/imgs/bro.png" alt="brobeur" width="800" height="180" />
    &lt;img src="http://www.trafficnz.info/camera/270.jpg" alt="Smiley face" width="250" height="200"&gt;
   <h1>
    <a href="/">
     BroBeur Studios
    </a>
   </h1>
   <nav>
    <ul>
     &lt;img src="http://www.trafficnz.info/camera/270.jpg" alt="Smiley face" width="250" height="200"&gt;
    </ul>
   </nav>
  </header>
  <!-- /#banner -->
  <section id="content" class="body">
   test!
   &lt;img src="http://www.trafficnz.info/camera/270.jpg" alt="Smiley face" width="250" height="200"&gt;
   &lt;
   &lt;img src="http://www.trafficnz.info/camera/270.jpg" alt="Smiley face" width="250" height="200"&gt;
   <img src="imgs/party.png" alt="party moon nightmare" width="300" height="186" />
  </section>
  <section id="extras" class="body">
   <div class="social">
    <h2>
     &lt;img src="http://www.trafficnz.info/camera/270.jpg" alt="Smiley face" width="250" height="200"&gt;
     xml feeds
    </h2>
    <ul>
     <li>
      <a href="/feeds/all.atom.xml" type="application/atom+xml" rel="alternate">
       atom feed
      </a>
     </li>
    </ul>
   </div>
   <!-- /.social -->
  </section>
  <!-- /#extras -->
 </body>
</html>


In [144]:
soupz.img.insert(0, incimg)

In [145]:
print soupz


<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>BroBeur Studios</title>
<link rel="stylesheet" href="/theme/css/main.css" />
<link href="/feeds/all.atom.xml" type="application/atom+xml" rel="alternate" title="A Pelican Blog Atom Feed" />
<!--[if IE]&gt;
            &lt;script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"&gt;&lt;/script&gt;
        &lt;![endif]-->
</head>
<body id="index" class="home">
<header id="banner" class="body">
<img src="/imgs/bro.png" alt="brobeur" width="800" height="180" />&lt;img src="http://www.trafficnz.info/camera/270.jpg" alt="Smiley face" width="250" height="200"&gt;
<h1><a href="/">BroBeur Studios</a></h1>
<nav><ul>
</ul></nav>
</header><!-- /#banner -->
<section id="content" class="body">
test!&lt;img src="http://www.trafficnz.info/camera/270.jpg" alt="Smiley face" width="250" height="200"&gt;&lt;&lt;img src="http://www.trafficnz.info/camera/270.jpg" alt="Smiley face" width="250" height="200"&gt;
<img src="imgs/party.png" alt="party moon nightmare" width="300" height="186" />
</section>
<section id="extras" class="body">
<div class="social">
<h2>&lt;img src="http://www.trafficnz.info/camera/270.jpg" alt="Smiley face" width="250" height="200"&gt;xml feeds</h2>
<ul>
<li><a href="/feeds/all.atom.xml" type="application/atom+xml" rel="alternate">atom feed</a></li>
</ul>
</div><!-- /.social -->
</section><!-- /#extras -->
</body>
</html>


In [85]:
brohtm = opstatic.text

In [86]:
ls


121.jpg  170.jpg  223.jpg  273.jpg  linkz
130.jpg  212.jpg  270.jpg  274.jpg  lorde

In [433]:
import PIL

In [502]:
from PIL import Image, ImageFilter, ImageEnhance, ImageChops, ImageColor

In [503]:
imx = Image.open('130.jpg')

In [503]:


In [504]:
im = Image.open('121.jpg')

In [505]:
imx.show()

In [506]:
imresiz = imx.resize((512, 512))

In [507]:
izresiz = im.resize((512, 512))

In [489]:
izresiz.show()

In [487]:
imresiz.show()

In [508]:
im.size


Out[508]:
(352, 240)

In [509]:
imx.size


Out[509]:
(704, 576)

In [510]:
pilspi = im.split()

In [511]:
for otwo in pilspi:
    print otwo.show
    otwo.show()


<bound method Image.show of <PIL.Image.Image image mode=L size=352x240 at 0x3549758>>
<bound method Image.show of <PIL.Image.Image image mode=L size=352x240 at 0x3549710>>
<bound method Image.show of <PIL.Image.Image image mode=L size=352x240 at 0x3549368>>

In [473]:
otwo.show()

In [474]:
iz = ImageEnhance.Contrast(im)

In [475]:
iz.enhance(1.10).show()

In [461]:
im.show()

In [490]:
imz = ImageChops.difference(izresiz, imresiz)

In [491]:
imz.show()

In [492]:
inb = ImageChops.subtract(izresiz, imz)

In [499]:
incv = ImageChops.darker(inb, izresiz)

In [500]:
incv.show()

In [501]:
incv.mode


Out[501]:
'RGB'

In [515]:
inzx = incv.getcolors(12)

In [518]:
inzx.


  File "<ipython-input-518-1e973386cac6>", line 1
    inzx.
         ^
SyntaxError: invalid syntax

In [493]:
inb.show()

In [519]:
%%bash
curl -k -H "username: williammckee" -H "password: J3e6t8q5y2" -o linkz https://infoconnect1.highwayinfo.govt.nz/ic/jbi/TrafficConditions2/REST/FeedService/?wsdl


  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 28422    0 28422    0     0  31210      0 --:--:-- --:--:-- --:--:-- 31198

In [522]:
%%bash
curl -k -H "username: williammckee" -H "password: J3e6t8q5y2" -o linkz https://infoconnect1.highwayinfo.govt.nz/ic/jbi/VariableMessageSigns2/REST/FeedService/?wsdl


  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   165    0   165    0     0    265      0 --:--:-- --:--:-- --:--:--   266

In [88]:
opzli = open('linkz', 'r')

In [89]:
opzli.read()


Out[89]:
"<?xml version='1.0' encoding='UTF-8'?><Fault><faultcode>Server</faultcode><faultstring>You are not authorised to access the requested resource.</faultstring></Fault>"

In [527]:
import pylast

In [529]:
password_hash = pylast.md5(passworz)
network = pylast.LastFMNetwork(API_KEY, api_secret =
API_SECRET, username=username, password_hash=password_hash)

In [532]:
artLord = 'lorde'

In [533]:
artist = network.get_artist(artLord)

In [539]:
artist.get_bio_content()


Out[539]:
u''

In [541]:
hercov = artist.get_cover_image()

In [544]:
Image(filename=hercov)


---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-544-8b0ccdd95cd1> in <module>()
----> 1 Image(filename=hercov)

TypeError: 'module' object is not callable

In [546]:
with open('lorde', 'wb') as handle:
    response = requests.get(hercov, stream=True)

    for block in response.iter_content(1024):
        if not block:
            break
        handle.write(block)

In [550]:
pwd


Out[550]:
u'/home/will/Desktop/highwaypiz'

In [540]:
artist.get_cover_image()


Out[540]:
u'http://userserve-ak.last.fm/serve/_/97285461/Lorde+PNG.png'

In [549]:
Image(filename='lorde')


---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-549-cab19ed4ba85> in <module>()
----> 1 Image(filename='lorde')

TypeError: 'module' object is not callable

In [536]:
artist.get_bio_content


Out[536]:
<bound method Artist.get_bio_content of pylast.Artist('lorde', pylast.LastFMNetwork('917060f2353e4ad89224f2295e146ddf', '9407d29e78647abbc1bc440d94aa1f70', '8f59f42472508b10d337a6ae069ca0a5', 'galf666', '02854afb05227c613afda7d9e5303a9f'))>

In [ ]:
'''
Created on 6/12/2012
 
@author: Will
'''
import pylast
import pprint
#from subprocess import Popen

password_hash = pylast.md5(passworz)
 
network = pylast.LastFMNetwork(API_KEY, api_secret =
API_SECRET, username=username, password_hash=password_hash)
 
#arti = input("Enter the artist name: ")
 
artLord = input('Artist: ')
artist = network.get_artist(artLord)
 
#album = network.get_album(artist)
 
 
artBio = artist.get_bio_content()
#pprint.pprint(artBio)
#artSimilar = artist.get_similar(20)
#artSimilar = str(artSimilar)
#pprint.pprint(artSimilar)
 
artImage = artist.get_cover_image(size=4)
#pprint.pprint(artImage)
#Popen(["firefox", artImage])
 
#artDefulat = artist.get_top_albums()
#artDefalat = str(artDefulat)
#pprint.pprint(artDefulat)
 
artPower = artist.get_bio_summary()
artPower = str(artPower)
#pprint.pprint(artPower)
 
 
 
doc = open('LastData', 'w')
doc.write('<h2><b>')
doc.write(artLord)
doc.write('</h2></b>')
#doc.write(artBio)
doc.write('Breaking News: ')
#doc.write(artPower)
doc.write(' - ')
#doc.write(artDefalat)
doc.write('<img class=\"aligncenter\" alt=\"\" src =\"')
doc.write(artImage)
doc.write('\" width=\"60\" height=\"30\" />')
#doc.write(artSimilar)
doc.close