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

1316 observed area #2860

Merged
merged 34 commits into from
Nov 11, 2022
Merged

1316 observed area #2860

merged 34 commits into from
Nov 11, 2022

Conversation

shokiami
Copy link
Collaborator

@shokiami shokiami commented Apr 13, 2022

Resolves #1316
Resolves #2329

After a long hiatus (sorry for the wait 😅), I finally implemented a rough draft for the observed area PR!
Here's what it looks like:
observedArea
One design decision I made that deviates from what we have talked about is measuring the observed area percentage in terms of the area instead of angles. For example, the image above depicts a user who just took a step while auditing, and although the user has not yet swiveled around in their new position, since the observed area from the previous position bleeds into the new one, it measures their current observed area as being ~83%.
Also, here are some relevant feeds:
#1316
#1324
#2329

@shokiami shokiami requested review from misaugstad and jonfroehlich and removed request for jonfroehlich April 13, 2022 02:04
@shokiami
Copy link
Collaborator Author

@jonfroehlich @misaugstad Thoughts?

@jonfroehlich
Copy link
Member

Yay! So great to see this revived!

I think this is really thoughtful and I'd like to try it out to get a better sense of things:

One design decision I made that deviates from what we have talked about is measuring the observed area percentage in terms of the area instead of angles. For example, the image above depicts a user who just took a step while auditing, and although the user has not yet swiveled around in their new position, since the observed area from the previous position bleeds into the new one, it measures their current observed area as being ~83%.

Sometimes, however, it is useful to see things from two different perspectives (e.g., looking at something from the south-to-north then taking a step north and looking back north-to-south)—I find this particularly helpful for surface problems.

@shokiami
Copy link
Collaborator Author

@jonfroehlich That makes sense—didn't think of that!
Also, I was curious:
My understanding of the purpose behind measuring the observed percentage is to hold users accountable and thus promote better data quality. However, how exactly will we be doing this? For example, will we prevent users from making a step until they fully observe the current area 100% (I feel like this is a little harsh)? Or maybe we can give users a thoroughness score on their profile (which may incentivize users to be more careful with their auditing). I feel like depending on the way in which we use this metric, it could make more sense to calculate the observed percentage using area over angles or vice-versa.
Please let me know what you think!

@misaugstad
Copy link
Member

I don't expect us to prevent people from moving before they've spun around (this would be incredibly frustrating on streets with no sidewalks at all). So I agree that it's a bit harsh ;)

I think that what's most important to us right now is that it's shown in a visually clear and appealing way, and that we are able to record this information so that we can use it later. We might start by just recording a percentage for each pano or possibly street. Then once that's live for awhile, we might then explore with that data a bit to see if it has a predictive effect on data quality, and come up with exactly we want our metric to be at that time.

And we would likely add this to a user's dashboard. Possibly the leaderboard. And possibly as a part of our heuristics for determining data quality from a user.

Sometimes, however, it is useful to see things from two different perspectives (e.g., looking at something from the south-to-north then taking a step north and looking back north-to-south)—I find this particularly helpful for surface problems.

I have to agree with @jonfroehlich on this. If one sidewalk block is raised above an adjacent one, that's generally really clear when looking at it from the side with the lower block, and often very hard to see from the side with the raised sidewalk block.

As such, doing a strict "observed area" method like you have right now would have the downside of discouraging users from looking backwards. I just tried out your PR. It looks so good!! If turning around to check from another angle wasn't so important, I would be 100% all in on the current method.

I'm trying to think about possible ways to visualize that you've looked through your previous panos successfully...

One idea could be to a small, circular "progress bar" thing at each panorama location that you enter. And those could persist on the mini-map after you leave the pano. To encourage you to leave a trail of fully complete progress bars in your wake. But that adds a decent amount of visual clutter.
Screenshot from 2022-04-14 12-56-53

Maybe the fog of war could have 3 levels instead of 2? One for not being explore, one for when it has been looked at from one angle, and another for when it's been looked at from both directions? Not sure how complicated that is to code up... I guess it would probably look like having two objects holding "observed areas"; one for areas you observed that were in front of you, and one for observed areas that were behind you. And you could use the angle you should be facing to move forward down the street to determine in front / behind. Though this could get wonky at intersections 🙃 Idk just spitballing here.

Any thoughts @shokiami ?

@jonfroehlich
Copy link
Member

Great discussion. To be clear, I wasn't suggesting that we prevent people from moving before meeting some observation threshold—this isn't consistent with our general user experience philosophy and the open exploration game-like experience. :)

I like both of Mikey's suggestion. We have been talking about totally redesigning the right sidebar area and I could imagine including something like this:
image

I also like the idea of visualizing three states in mini map:
image

  1. What you previously observed
  2. What you've observed in this pano
  3. What you haven't observed in this pano

But visualizing those three states in the mini map would take careful design...

I wonder if we should ship what Sho has currently and then make a new Issue for these new ideas that we could pursue (especially if Sho still has cycles, since it would be most efficient for them to continue on this track rather than delegating to someone else).

@shokiami
Copy link
Collaborator Author

@misaugstad I'm glad you like it :) and that makes sense! I just wanted to clarify our intended use of the observed area thoroughness data before making further assumptions about the problem. So I'll go ahead and switch it back to using angles (unless there is some other metric you want me to use).
I agree that adding a circular progress bar for every previously observed area would be a lot of visual clutter. I like what Jon is suggesting though which is to add a single progress bar for the current location. If we were to do this, do you think it would look better in the sidebar or the mini-map?
Ooh, I'm intrigued by this idea of having 3 levels of the fog-of-war! It might get complicated, but I'll do my best to implement it to see how it looks. Also, do you think that this should have any effect on our observed area thoroughness data we are collecting?
@jonfroehlich I'm more than happy to continue working on this project! A little confused about what you mean by "cycles"... I'm still in my second year if that answers your question.

@jonfroehlich
Copy link
Member

jonfroehlich commented Apr 15, 2022 via email

@shokiami
Copy link
Collaborator Author

shokiami commented Aug 1, 2022

@jonfroehlich @misaugstad
After some time messing around with the 3 levels of fog-of-war proposed earlier by Mikey, I'm struggling to come up with anything practical/effective, so I think it would be best if we followed Jon's suggestion of shipping the current changes and creating a new issue (which I can do if you want).

Here is what everything looks like right now:
Untitled

To summarize, this PR introduces:

  1. A user's FOV that accurately reflects what the user can see on the GSV mini-map.
  2. A fog-of-war that is cleared away by the user's FOV.
  3. A progress bar that keeps track of how much the user has observed in the current location (% of 360 degrees).

Note: this PR also resolves #2329

@jonfroehlich
Copy link
Member

Sounds good to me! Kudos for continuing to push this forward.

Can you create a new Issue for discussing how to incentivize people to look backwards at an area after taking "a step" forward?

@shokiami
Copy link
Collaborator Author

shokiami commented Aug 1, 2022

@jonfroehlich Just did: #2982
@misaugstad Are we ready to merge then?

@misaugstad
Copy link
Member

Are we ready to merge then?

I'll need to do some testing and review the code. @shokiami do you want me to do the full PR review? Or if there are just some code organization/efficiency changes to make, should I just make them myself? Not sure what your internship workload is looking like.

@shokiami
Copy link
Collaborator Author

shokiami commented Aug 1, 2022

@misaugstad Feel free to do the full PR review!

@jonfroehlich
Copy link
Member

If that doesn't work, you might have to draw a black outline around the lettering and circle. I can help with that if relevant in the future.

@misaugstad
Copy link
Member

After a quick look, @shokiami and I talked about this and we agreed that the code for the mini map should live in it's own file, and we can put it in the /navigation directory. @shokiami if you want to start moving some of the other functionality related to the mini map into that file, feel free, but that can also be separated out into it's own issue later on!

@shokiami
Copy link
Collaborator Author

shokiami commented Nov 6, 2022

@misaugstad @jonfroehlich
So sorry for the delay 😅, but I had some time today so I quickly addressed Mikey's bug by moving the observed area code to a new file so that the observed area persists across tasks.
Also, I tried changing it so that when the user hits 100% observed, the fog of war turns green instead of the progress bar:
1
2
I think that looks pretty good and is nice and obvious for the user too. Please let me know what you guys think!

@shokiami shokiami requested a review from misaugstad November 7, 2022 05:37
@jonfroehlich
Copy link
Member

Very cool @shokiami. I can't wait to ship this long-awaited feature! 🚀

One thing I just thought of--which would be simple to add just not certain on the text, which would need to be very concise and clear:

image

@shokiami
Copy link
Collaborator Author

shokiami commented Nov 8, 2022

@jonfroehlich
Great idea! Just added that. (I also added the relevant translations in Spanish and Dutch).

Copy link
Member

@misaugstad misaugstad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome work, @shokiami! This looked really good. The restructure was great. We were so close to being done, and I wanted to push out a new version of Project Sidewalk this week, so I did the final little edits myself so that we could get it pushed out!

Some changes:

  • All the mini map stuff was called google-maps or googleMap, which felt confusing, so I renamed all of those to minimap. That's part of your code specifically, but it's an extra little change I made on top of it.
  • I switched up how you keep track of the list of observed areas. Instead of making sure that the current one is at the end of the list, I just made a new currArea variable that keeps track of that. And we now use the panoId as the index instead of the latLng.
  • I didn't like how the green fog of war looked, it was a pretty jarring change. I switched it back to having a gray fog of war always, and making the circle turn green when you reach 100%. I just kept the text black, since the main issue with the green progress circle was that you couldn't read the text when it turned green.

Here's what things look like now!
Screenshot from 2022-11-10 16-21-17
Screenshot from 2022-11-10 16-21-46
Screenshot from 2022-11-10 16-22-00

@misaugstad misaugstad merged commit 2100aad into develop Nov 11, 2022
@misaugstad misaugstad deleted the 1316-observed-area branch November 11, 2022 00:27
@shokiami
Copy link
Collaborator Author

Awesome, thank you so much @misaugstad!

@misaugstad misaugstad mentioned this pull request Nov 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Map avatar view indicator on sidebar Consider bringing back 'observed area' feedback
3 participants