109 lines
8.3 KiB
Plaintext
109 lines
8.3 KiB
Plaintext
|
|
Episode: 1816
|
||
|
|
Title: HPR1816: Visualising HPR tags
|
||
|
|
Source: https://hub.hackerpublicradio.org/ccdn.php?filename=/eps/hpr1816/hpr1816.mp3
|
||
|
|
Transcribed: 2025-10-18 09:39:21
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
This in HPR episode 1,816 entitled Visualizing HPR Tab.
|
||
|
|
It is hosted by Dave Morris and in about 9 minutes long.
|
||
|
|
The summary is using Bluff Vista Visualizing Tab on HPR episodes.
|
||
|
|
This episode of HPR is brought to you by an Honesthost.com.
|
||
|
|
Get 15% discount on all shared hosting with the offer code HPR15.
|
||
|
|
That's HPR15.
|
||
|
|
Better web hosting that's Honest and Fair at An Honesthost.com.
|
||
|
|
Hello everyone, this is Dave Morris.
|
||
|
|
Today I'm going to do a different type of show from the way I normally do things.
|
||
|
|
Content might be a bit different, certainly the way I do it is a bit different.
|
||
|
|
I'm just trying to do this in a pretty much off the cuffway.
|
||
|
|
I thought I'd share with you a thing I've been playing around with.
|
||
|
|
I came up with the idea yesterday and put together some software to make my idea real.
|
||
|
|
The idea is based around the HPR database.
|
||
|
|
In the database there is an entry per show, not too surprisingly.
|
||
|
|
And in this entry, in this row in the database,
|
||
|
|
one of the things that's stored there is a list of tags.
|
||
|
|
You'll be aware hopefully that you are asked to provide some tags when you submit a show these days.
|
||
|
|
I think this is a relatively recent invention. Ken would would remind me but I haven't asked him
|
||
|
|
within the past year or so the tags came along.
|
||
|
|
We're not doing much with them at the moment but we're thinking of
|
||
|
|
using them to give more information about shows in general.
|
||
|
|
Anyway, there's this list of tags and I was looking at them.
|
||
|
|
We really need to populate them and that means we could do with crowd sourcing
|
||
|
|
this amongst the HPR community asking people to look at, select a show, look at it,
|
||
|
|
or listen to it more at the point and come back with a set of tags which we can then add to the
|
||
|
|
database. One of the things about adding tags though is quite useful to know what tags exist.
|
||
|
|
We need to do some sort of standardization anyway.
|
||
|
|
So I thought what I would do is try and analyse what we have at the moment with the view to just
|
||
|
|
get my head around what we could do in the future.
|
||
|
|
So what I thought I'd do would be to make a graphical representation of the tags
|
||
|
|
in the shows that have tags at the moment which is not very many.
|
||
|
|
Back in the day when I was at work I used to mess around with the package called
|
||
|
|
GraphViz. There'll be a link in the show notes to this. It's still going strong.
|
||
|
|
In fact it's developing, it has developed quite a lot from the way I knew it.
|
||
|
|
GraphViz is a package which lets you define items, whatever they are,
|
||
|
|
nodes in the parlance which are words or structures or whatever.
|
||
|
|
And then join them together in various ways. So you define
|
||
|
|
here's a node, here's its name, here's what I'd like you to label it.
|
||
|
|
Various things about its colour and how you want it drawn and things like that.
|
||
|
|
And then you then say I want to create an edge.
|
||
|
|
An edge is the line between one node and another.
|
||
|
|
So the way I decided to do this was to write a purl script. Of course in purl there's
|
||
|
|
an interface to this GraphViz package. And what I'm actually doing is I'm going through
|
||
|
|
the database, finding all records which contain tags.
|
||
|
|
And then I'm returning the show number, the title of the show and the list of tags.
|
||
|
|
Then in my script, the script will be available in the show notes.
|
||
|
|
In the script I'm parsing out the tag list, separating them out by commas.
|
||
|
|
And I'm building a structure where it's indexed by tag and attached to each tag,
|
||
|
|
the list of all the shows that have that tag. So having built this structure which is meant
|
||
|
|
to represent the sort of picture I want and then using GraphViz to simply walk through this
|
||
|
|
thing through the tags in a sorted order. I don't think it actually matters because GraphViz has
|
||
|
|
a bit of a mind of its own. I'm walking through the tags anyway and for each tag I create a node
|
||
|
|
with a label of the tag. So you'll see this in the notes as to how this turns out. And then I'm
|
||
|
|
walking through the list of IDs associated with that tag and making nodes from them. Each
|
||
|
|
ID I'm turning it into the string HPR followed by a four digit number, then the title of the show
|
||
|
|
on a new line. And it's in a box with a green border. And then I'm doing an ad edge,
|
||
|
|
is the call you need to do to make a link between the tag box, it's actually an oval in the current
|
||
|
|
iteration, and the show number, show name, show title box. And once that's all been done and there's
|
||
|
|
something like, check my list, we've got 727 tags and 303 shows with those tags. So that's pretty
|
||
|
|
small number in comparison to the number of shows, which is in the 1800s now as you probably know.
|
||
|
|
Then I run the graphical, the GraphViz application to make it produce the output. What it does
|
||
|
|
is it's creating an SPG file which you can then look at in a browser. And I'm putting this in my show
|
||
|
|
notes so that you can gaze at this. It's pretty big and it's not anything very beautiful,
|
||
|
|
but it is interesting, very least anyway, I find it interesting. You might too as well. So
|
||
|
|
just looking at it at the moment and how it's laid out, I've made it do the tags in red ovals
|
||
|
|
on the left and the show details on the right in green boxes as I said. And then there are arrows.
|
||
|
|
So for example, at the top of the display at the moment, I've got teachers as a tag and tutorials
|
||
|
|
as a tag. And they're pointing at show 1735, which is in type of free tutorials for teachers.
|
||
|
|
So that's actually quite simple. It's only got two tags. If you scroll further down and it's a long
|
||
|
|
scroll to get to the end of it, you start to see things like, well, if you look for the word
|
||
|
|
Linux, and there's no way of searching in this, but it's more of an exercise in showing what's
|
||
|
|
in there, I think. I'm not sure this would ever be a practical thing. This isn't the way to
|
||
|
|
produce tag clouds and I don't think, but I thought it was an amazing thing. I thought you might
|
||
|
|
be interested in it. Let's find one. See, I've got HPR Live as a tag and it's pointing at shows 1411
|
||
|
|
and 1413, which are Omrup Live shows that need ODE, if I remember rightly. So I hope that if you
|
||
|
|
looked at this, and I look at this, this one, I'm going to do a show, this one, particularly,
|
||
|
|
there'll be a bit more of a clue as to what sort of tags are out there and what people are doing
|
||
|
|
and doing with them. And I hoped it might generate a bit of discussion about using tags and get people
|
||
|
|
enthusiastic about adding something to shows. So as you scroll way down this list and you start to
|
||
|
|
find that things get pretty tangled. And I'm not quite sure how it's all ordered these. It's
|
||
|
|
graph is made its own decision about how this is to be done, but you start to find that the
|
||
|
|
plate of spaghetti problem starts to manifest big time. And so, for example, if you find
|
||
|
|
Android, I think there's only about three links from Android to stuff, but the way the thing is
|
||
|
|
optimised it, you can't actually follow the lines from that at all. And if you find Linux,
|
||
|
|
a lot of shows been tagged with Linux, then it's just ridiculous. It just goes into a revolting
|
||
|
|
tangle. Now, if I understood graph is better, then there might be ways in which I could optimise
|
||
|
|
this. I've been fiddling around with the attributes and there's a new enormous number of them.
|
||
|
|
Not too any great success to be honest with you, but it's something I'm going to mess around with
|
||
|
|
a bit longer, just from my own amusement more than anything else. So, right. So the show notes
|
||
|
|
will contain the script, which is not very big. It's only 200 lines long and it will contain
|
||
|
|
a bunch of links to things to do with graph is and it's going to, you should be able to find the
|
||
|
|
the latest SVG image from my experimentation. So, let me find that. It's interesting. Okay, bye.
|
||
|
|
You've been listening to Hecker Public Radio at Hecker Public Radio. We are a community podcast
|
||
|
|
network that releases shows every weekday Monday through Friday. Today's show, like all our shows,
|
||
|
|
was contributed by an HPR listener like yourself. If you ever thought of recording a podcast,
|
||
|
|
then click on our contribute link to find out how easy it really is. Hecker Public Radio was
|
||
|
|
founded by the digital dog pound and the infonomicum computer club and it's part of the binary
|
||
|
|
revolution at binrev.com. If you have comments on today's show, please email the host directly,
|
||
|
|
leave a comment on the website or record a follow-up episode yourself. Unless otherwise status,
|
||
|
|
today's show is released under Creative Commons, Attribution, ShareLite, 3.0 license.
|