Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Haro Strait vs Straight #145

Closed
dthaler opened this issue Jun 5, 2024 · 7 comments · Fixed by #153
Closed

Haro Strait vs Straight #145

dthaler opened this issue Jun 5, 2024 · 7 comments · Fixed by #153
Assignees
Labels
2024-hackathon Goals or issues for the 2024 annual Microsoft hackathon Addressed by #155 good first issue Good for newcomers moderator portal Issues pertaining to ModeratorPortal at https://aifororcas.azurewebsites.net

Comments

@dthaler
Copy link
Collaborator

dthaler commented Jun 5, 2024

https://aifororcasdetections.azurewebsites.net/swagger/index.html and various other files show "Straight" whereas the actual name is "Strait". (And neither of them match the live.orcasound.net name for it of "Orcasound Lab".)

@scottveirs scottveirs added good first issue Good for newcomers moderator portal Issues pertaining to ModeratorPortal at https://aifororcas.azurewebsites.net 2024-hackathon Goals or issues for the 2024 annual Microsoft hackathon labels Jul 19, 2024
@scottveirs
Copy link
Member

Since there are already two hydrophone monitoring sites in Haro Strait, another underdevelopment on the Canadian side, and Orcasound plans for another 1-2, I'd 2nd Dave's suggestion to standardize by switching to the "Orcasound Lab" label.

For future-proofing, it would be ideal for the Moderator Portal and other apps using the Swagger API to all utilize the Orcasound API for assigning labels when a new node is integrated in the OrcaHello real time inference system.

@micya
Copy link
Member

micya commented Jul 23, 2024

I feel like the proper fix is to use some kind of unique ID (ex: GUID) for each site and have a single mapping from ID to location string. That would make updates easier in case we decided to rename the location (ex: Haro Strait 1/2/3 or some other more descriptive naming).

@dthaler
Copy link
Collaborator Author

dthaler commented Jul 24, 2024

I agree that using a unique ID internally is important, but it's also important to use a consistent display name across sites. Currently https://live.orcasound.net/api/json/feeds has multiple identifiers it provides:

  • "id": "feed_02u8r4ELz2xkCjPTc4yLWE"
  • "name": "Orcasound Lab"
  • "node_name": "rpi_orcasound_lab"
  • "slug": "orcasound-lab"

"id" is, I believe, the unique ID for the hydrophone.

"name" is a display name and could be renamed.

"node_name" is a path component used in constructing the S3 path. In theory it could be changed but then one would either have broken URIs or one would have to enable redirects.

"slug" is a path component used in constructing the orcasound.net path. In theory it could be changed but then one would either have broken URIs or one would have to enable redirects.

@dthaler
Copy link
Collaborator Author

dthaler commented Jul 24, 2024

There's also a unique ID on dataplicity that is a GUID:
"serial": "84bb6fee-b38c-488e-adac-1a36bbb9a4da",

I am not sure why orcasound.net doesn't expose it and instead exposes some other "id".

@skanderm
Copy link

skanderm commented Jul 24, 2024

That id column (feed_) is unique and is backed by a UUIDv7 (in the orcasite db), which I'd be happy to surface. I could also add a field to keep track of the dataplicity ID, but I assume that represents the hardware node in their system.

Let me know if you'd like either of those changes!

@dthaler
Copy link
Collaborator Author

dthaler commented Jul 24, 2024

I think exposing the dataplicity "serial" value would be helpful.
That would allow the "slug" value to be renamed in dataplicity without breaking the linkage between orcasite and dataplicity.

dthaler added a commit to dthaler/aifororcas-livesystem that referenced this issue Jul 26, 2024
Fixes orcasound#145

Signed-off-by: Dave Thaler <dthaler1968@gmail.com>
dthaler added a commit to dthaler/aifororcas-livesystem that referenced this issue Jul 26, 2024
Fixes orcasound#145

Signed-off-by: Dave Thaler <dthaler1968@gmail.com>
dthaler added a commit to dthaler/aifororcas-livesystem that referenced this issue Jul 26, 2024
Fixes orcasound#145

Signed-off-by: Dave Thaler <dthaler1968@gmail.com>
@paulcretu
Copy link
Member

Great question, so far projects have grown organically and we haven't really formalized a source of truth / data schema for hydrophone node/feed/location metadata. It's something to figure out as more projects spring up.

For the time being, I agree that orcasite (https://live.orcasound.net) is the de facto source of truth. As a primary ID, I would rather rely on our internal ID (feed_) rather than dataplicity's, as our ID should never change (and we generated it). Also we shouldn't couple too tightly to dataplicity in case we ever decide to use a different service. Seems like a great idea to include in the DB though, good call @dthaler and thanks for adding @skanderm.

The other identifiers seem less stable:

slug should be pretty reliable (@dthaler as you mention, it would break URLs) and seems like a good choice for something human readable. I can't imagine why it would ever change without also changing the UUID (feed_) but who knows?

node_name is indeed used for the S3 path, but more than that, it's also the name the hardware reports and uniquely identifies a device. Whenever we get around to improving orcanode code, it may be worth rethinking if the device ID should even be used for the S3 bucket name. In general, I think the idea of a feed/location should transcend the hardware, but of course, decoupling things always comes at a cost of more stuff to track.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2024-hackathon Goals or issues for the 2024 annual Microsoft hackathon Addressed by #155 good first issue Good for newcomers moderator portal Issues pertaining to ModeratorPortal at https://aifororcas.azurewebsites.net
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

6 participants