SnoopJ's Avatar

SnoopJ

@snoopj.hachyderm.io.ap.brid.gy

Hi, I'm James. Eternal dilettante and purveyor of nonsense, much of it about #Python, physics, and #cycling. I take part in #Monsterdon most Sundays at 9 PM ET [โ€ฆ] ๐ŸŒ‰ bridged from โ‚ https://hachyderm.io/@SnoopJ, follow @ap.brid.gy to interact

36 Followers  |  10 Following  |  2,198 Posts  |  Joined: 25.11.2024  |  2.8859

Latest posts by snoopj.hachyderm.io.ap.brid.gy on Bluesky

Video thumbnail

finally, we have the technology to make intersections look ugly

11.11.2025 06:52 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 0    ๐Ÿ“Œ 0

wow here I thought I was just going to do a little prototyping, and I've already hit my first goal and it's all greenfield from here

nice

11.11.2025 06:45 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0
Photo of a PyQt application showing a map of part of Boston and Cambridge, near the Boston University Bridge. Overlaid on the map are dozens of bicycle tracks, many laying along either side of the river, but some taking the streets on either side

Photo of a PyQt application showing a map of part of Boston and Cambridge, near the Boston University Bridge. Overlaid on the map are dozens of bicycle tracks, many laying along either side of the river, but some taking the streets on either side

I wrote a little script to convert FIT files to GPX and now it can render every activity I have recorded!

11.11.2025 06:44 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

```
if np.nanmin(lon) < -80:
LOGGER.warning("Skipping that one ride I took in New Mexico")
```

11.11.2025 06:06 โ€” ๐Ÿ‘ 0    ๐Ÿ” 1    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

me: I would like to do a project :)

computing: HERE IS SOME CURSED KNOWLEDGE REQUIRED TO DO YOUR PROJECT DO YOU ACCEPT [Y / MAYBE LATER]

11.11.2025 05:47 โ€” ๐Ÿ‘ 0    ๐Ÿ” 1    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0
Original post on hachyderm.io

huh so needing to handle a status code of 0 is a known quirk in Chromium, because the W3C specification is quite clear about setting 0 at the start of the process, but does not specify what should be done if an HTTP status code does not apply (as for the `file://` scheme) [โ€ฆ]

11.11.2025 05:47 โ€” ๐Ÿ‘ 0    ๐Ÿ” 1    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

@xgranade obligatory https://www.youtube.com/watch?v=tas0O586t80

11.11.2025 05:35 โ€” ๐Ÿ‘ 1    ๐Ÿ” 0    ๐Ÿ’ฌ 0    ๐Ÿ“Œ 0

god, I remember that Lexington used to feel impossibly far away by bike, and now it's just likeโ€ฆ a place I go frequently, because it's a nice ride!

that said, Concord is still pretty damned far away, I've only done *that* ride once.

11.11.2025 05:26 โ€” ๐Ÿ‘ 0    ๐Ÿ” 1    ๐Ÿ’ฌ 0    ๐Ÿ“Œ 0
Original post on hachyderm.io

well, I say "the" remaining trick as if I'm not dreaming of an entire application here

once I can display multiple GPX files, it will have reached feature parity with the old tool for showing my routes, with the bonus of having all the creature comforts of Leaflet

and *then* I can start [โ€ฆ]

11.11.2025 05:21 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

now the remaining trick is to convert my FIT files to GPX files

OR

to modify `leaflet-gpx` to work from FIT data instead of GPX data

not sure which of those is easier but *probably* the first one.

11.11.2025 05:18 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

let's ignore that squiggly bit in the middle, I got turned around badly in Alewife on my return because of the ongoing construction >_>

11.11.2025 05:16 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0
Screenshot of a PyQt application showing a map of Boston and a red path traced out on top of it along the Somerville Community Path and the Minuteman Commuter Bikeway

Screenshot of a PyQt application showing a map of Boston and a red path traced out on top of it along the Somerville Community Path and the Minuteman Commuter Bikeway

okay, I figured it out. `leaflet-gpx` isn't exactly expecting to be run locally, I think, and wasn't deal with an `XMLHttpRequest` response status of 0 (I suspect this is a familiar quirk to people who know the domain better than I do)

but anyway, now I have a [โ€ฆ]

[Original post on hachyderm.io]

11.11.2025 05:15 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 2    ๐Ÿ“Œ 0
PyQt application running Leaflet, showing a triangle drawn arbitrarily over downtown Boston

PyQt application running Leaflet, showing a triangle drawn arbitrarily over downtown Boston

consistency check: can I draw a random polygon? (yes)

11.11.2025 04:48 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

I managed to segfault it! :D

I can get the `leaflet-gpx` code loaded and successfully parse my reference GPX file, but I cannot get it to display on the leaflet map

11.11.2025 04:46 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

`Uncaught TypeError: this.callInitHooks is not a function`

statements dreamt up by the utterly embedded

11.11.2025 04:16 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

in hindsight it should have been obvious I'd be pissing around with JavaScript glue here

11.11.2025 04:02 โ€” ๐Ÿ‘ 1    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

@glyph I've seen encoded bytes you people wouldn't believe

11.11.2025 03:31 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 0    ๐Ÿ“Œ 0

hm, I can get `leaflet-gpx` to do what I wanted in a browser demo, but I can't reproduce the same thing in the little sandbox pyqtlet2 has set up

11.11.2025 03:31 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0
Screenshot of a PyQt application showing an embedded Leaflet map of Boston, with some overlaid text reading "HEH HEH HEH THIS IS MY TEXT"

Screenshot of a PyQt application showing an embedded Leaflet map of Boston, with some overlaid text reading "HEH HEH HEH THIS IS MY TEXT"

putzing around with PyQt a bit tonight

11.11.2025 03:08 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 2    ๐Ÿ“Œ 0

it is difficult to say how much time I spent reading Wikipedia but it's definitely A BUNCH

11.11.2025 03:05 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 0    ๐Ÿ“Œ 0

whoa, Wikipedia just went down for me for a moment

jump-scare moment

11.11.2025 03:05 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

CI/CD means "crashes immediately, can't debug"

11.11.2025 00:46 โ€” ๐Ÿ‘ 2    ๐Ÿ” 28    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

@bitprophet signed

11.11.2025 02:46 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 0    ๐Ÿ“Œ 0

@ozdreaming ah I think the meshes on either side of the door have inverted normals. common problem

11.11.2025 02:24 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0
A photo of a sign that is designed like the SEPTA logo, but it is the "Cool S" in the middle. The text reads, "SEPTA IS COOL". If you don't know what a "cool S" is, ask your nearest Millennial American.

A photo of a sign that is designed like the SEPTA logo, but it is the "Cool S" in the middle. The text reads, "SEPTA IS COOL". If you don't know what a "cool S" is, ask your nearest Millennial American.

I made a sign to support SEPTA #philly #philadelphia

19.08.2025 23:43 โ€” ๐Ÿ‘ 1    ๐Ÿ” 15    ๐Ÿ’ฌ 2    ๐Ÿ“Œ 0

@SnoopJ @bikepedantic.bsky.social if we could get the city to put effort into bikeshare being a point of city pride, getting a better bike network would be so much easier

10.11.2025 22:42 โ€” ๐Ÿ‘ 0    ๐Ÿ” 1    ๐Ÿ’ฌ 0    ๐Ÿ“Œ 0

@DemonHusky @bikepedantic.bsky.social I'm thinking more about load-balancing due to asymmetric flows/jitter. AFAIK this is just table stakes: you will always need to manually move bikes from [THERE] to [HERE] or end up with a deficit of parking somewhere because bikes have piled up.

10.11.2025 22:45 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 0    ๐Ÿ“Œ 0
Original post on mas.to

@SnoopJ @bikepedantic.bsky.social I think a major bit is swapping batteries, and you eliminate 90% of operations costs by electrifying 10% of stations. For balancing the system, just adding capacity to stations and more density likely (no insider knowledge here) reduce required van swaps. But at [โ€ฆ]

10.11.2025 22:40 โ€” ๐Ÿ‘ 0    ๐Ÿ” 1    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0
Original post on hachyderm.io

@DemonHusky @bikepedantic.bsky.social @notjustbikes yea this is kinda where the idea of roping libraries in came to me from. It's something there's already (some) civic pride in, and a bikeshare does share some concepts with lending (and there's prior art for lending tools etc.).

The same kind [โ€ฆ]

10.11.2025 22:39 โ€” ๐Ÿ‘ 1    ๐Ÿ” 0    ๐Ÿ’ฌ 1    ๐Ÿ“Œ 0

@DemonHusky @bikepedantic.bsky.social all that said, I hope the conversation about fare-free busses doesn't come to a screeching half just because Hochul opened her mouth on the subject. She was wrong about congestion pricing, and she's wrong about this.

10.11.2025 22:34 โ€” ๐Ÿ‘ 0    ๐Ÿ” 0    ๐Ÿ’ฌ 0    ๐Ÿ“Œ 0

@snoopj.hachyderm.io.ap.brid.gy is following 10 prominent accounts