I am having trouble creating a shortcut that finds and delete all of the videos that I take at a particular location.
My wife and I strength train virtually with a coach and have to submit our videos for form checks. We use our phones to upload them to our coach. I would like assistance in troubleshooting my shortcut that should do the following
@sebastienkb
Why did you use the distance from action? Is there no way to find videos from a particular location?
The way that I have this set up, it finds all videos, not just those in the location. What am I doing wrong?
Mumbai is a location, but to Shortcuts it is in effect a point on the surface of the earth, not a region. That’s what a location is. Think about a map pin rather than a city boundary.
Is that the same as Mumbai? No. It may be “close”, but it is not the same. This is because they are both points, not regions.
You are looking for videos taken in the region of Mumbai, not at a point in Mumbai, so to specify the region, you need to specify the central point and the distance from that point that specifies your region. You are effectively creating a tolerance level for matching your location (point).
I am trying to solve this without declaring the variable work_address as @sebastienkb has done given that I know the exact coordinates of the location where I film my videos.
As long as your GPS gives precisely the same value to about 14 or 15 decimal places on both the latitude and longitude you are fine… in other words, no.
The earlier point of point vs area still stands.
You could round off and compare the coordinates to fuzz them, but you are making things harder for yourself.
What is the reason for not wanting to use the variable you refer to? An arbitrary preference or something concrete?
GPS is not 100% accurate so you can’t just grab the GPS data and compare the numbers. You’ll find more info on GPS accuracy here: GPS.gov: GPS Accuracy
You also can’t lookup the corresponding postal address of each video in Shortcuts and check if the city reads “Mumbai” or else you’ll delete ALL videos taken in ALL of Mumbai, which is a way bigger area than what you are aiming (your gym place).
The least error-prone way to work with this is to get the GPS location of each video and see if it’s within a specific range of a fixed GPS location (your gym place), hence the use of a variable and Get Distance inside the Repeat loop. Shortcuts doesn’t provide an easy way to type a precise GPS location so looking up the place in the field I showed is the easiest way. Any other way of comparing GPS points is a headache.