How much storage space is required to host all the images of Google Street View?
You'll get access to over 3,000 product manager interview questions and answers
Recommended by over 100k members
Answering Google estimation interview questions almost always starts with asking clarifying questions. In this case, you need to know how many images are taken and the average size of each one. You can then move into the calculation phase.
Total Storage space = Space required for one Picture X Number of images
Assume Space required for one Picture = 20MB
Number of Images : Total length of Street covered by Google (KM) X No of Pic per KM
From experience we know that that average distance between pictures on street view is 10m
Therefore :
No of Pic per KM = 1000/10 = 100
Now lets calculate the Total length of Street covered by Google (KM)
Radius of Earth = 6500Km (approximately)
Surface Area = 4 Pi R(2)
= 4 * 3.148 *(6500 *6500) = 532012000
= 500 M Km2
70% of Earth is covered by water
Land Area = 30 % of 500 M Km2 = 150 M Km2
50% of land is covered by desert and mountains so lets assume only 50% is habitable
Therefore : Habitable land = 50% of 150 M Km2 = 75 M Km2
Google maps does not have coverage over 100% of habitable land. Some large countries like China do not have street view. So we have to assume google has coverage approximately over 55% of Habitable land
Google Coverage = 40 M Km2 (approximate)
Now lets calculate the Length of street in this area (in Kms)
Not all areas have the same density of roads.
Let us assume that we can divide the Google Coverage area into 4 level of road density
Road Density | % | Km of Road / 10 km2 | Weighted Average |
Very Low | 50% | 5 | 2.5 |
Low | 30% | 20 | 6 |
Medium | 15% | 50 | 7.5 |
High | 5% | 100 | 5 |
|
|
| 5.25 |
Therefore Average length of street per 10 Km2 = 5 km
Total length of Street in google coverage area of 40 M Km2 = 5/10 * 40 M = 20 M Kms
Using the formula
Number of Images : Total length of Street covered by Google (KM) X No of Pic per KM
Number of Images : 20 M X 100 = 2000 M
Total Storage space = Space required for one Picture X Number of images
Therefore :
Total Storage space = 20MB X 2000 M
= 40,000 TB
To estimate the storage needed for all pictures, I need two pieces of information to help me come up with an estimate: 1- average size of an image 2- number of images taken.
Let’s say each 360 degree image on Google Street View is 20MB. I’m picking a large number because Google Street View images are usually 360 degrees. And If they are not, we can assume that the some of images taking from one spot to cover all angles is 20MB.
To calculate total number of images on Google Street View, I have to calculate total # of images per km x # of km’s covered in Google StreetView.
To estimate number of images per KM, I think about my own experience using Google StreetView. I’ve noticed that the smallest move I can make to change my view of a street is about 10 meters. Let’s assume that on every 1km (1,000 meters), there are 1000/10 = 100 images.
Now, we need to calculate number of KM’s of street covered by Google StreetView.
Ideally, Google Street View can cover all streets around the world and that’s the direction that it’s going. So, I’m going to come up with total distance of all streets around the world for the 7 billion population earth. Let’s assume 2billion people live in towns and 5 billion live in cities.
To estimate total distance of streets in towns, we can look at total distance for a 2,000 person town first and then multiple that number by 1million. Let’s assume all 2,000 people live in houses and distance between houses is about 10 meters. So, if each house consisted of 4 people, we would have a total of 2,000/ 4 = 500 houses. If all houses were in one street on both sides of the street, we would have about 5,00 houses x 10 meters / 2 = 2,500 meter of street covering houses. So, for every 2,000 people in a small people, there is 2.5km of street.
I should mention that in reality all houses are not in one street and some might be in by an intersection, meaning they are connecting two streets but then there are also streets with no houses (e.g. commercial area) so for the sake of this estimation, I will assume that for every 2,000 people in a town, there are about 2.5 km of street. In order words, for 2 billion people who live in towns, there are 2.5 million km of streets. This is a very rough estimate because in some small towns, there might be apartments and people might live in in denser neighbourhoods. But then there can also be places where distance of houses is more than 10meters. So we’ll assume 10meters is the average distance between the houses in towns.
For cities, let’s breakdown the population to two groups: 50% live in houses – 2.5 billion live in houses in cities. 50% live in apartments – 2.5 billion live in apartments in cities. Let’s say that for those who live in houses, average people in a house is 3 and distance between houses is 10 meters. In other words, for 2.5 billion people who live in houses in cities, we have about (2.5 billion / 3) = 800million houses. Assuming distance between houses is again 10 meters and houses are on both sides of the street, we have a total of 800 million x 10 meter / 2 = 4 billion meters or 40 million km of street.
To estimate street for 2.5 billion people who live in apartments, let’s say that on average every 100 people live in one building. And distance between apartments is 100 meters. Assuming apartments are on both sides of the street, we can say that for every 100 people, we have 100 / 2 = 50 meters of street. In other words, for 2.5 billion people, we have 1.25 billion meter or 12.5 million km of street.
Now, people in cities usually work in offices and shops. Let’s say that on average 20% of people who live in cities work – estimated population would be 20% of 2.5 billion = 500 million. And every office building includes 100 people and distance between office buildings is 100 meters. Assuming office buildings are on both sides of the streets, for every 100 people, there are 100 / 2 = 50 meters of street for their office. In other words, for 500 million people living in cities, there are 250 million meter or 0.25 million km of street.
Now, let’s add all numbers together:
2.5 million km (representing towns) + 40 million km (representing houses in cities) + 12.5 million km (resenting apartments in cities) + 0.25 million km (representing offices in cities) = 55.25 million km of street in total
Now, given each km includes 100 images and each image is 20MB, total size of all StreetView images is:
55.25 million km x 100 images per km x 20MB of file = 110.5 million GB = 115 thousand TB.
Total size of all images to be stored on Google Street view would be 115 thousand TB.
Top Google interview questions
- What is your favorite product? Why?89 answers | 263k views
- How would you design a bicycle renting app for tourists?62 answers | 82.5k views
- Build a product to buy and sell antiques.54 answers | 66.8k views
- See Google PM Interview Questions
Top Estimation interview questions
- Calculate the number of queries answered by Google per second.45 answers | 78.5k views
- How do you decide how many cash registers you need for a new Walmart store?33 answers | 39.4k views
- How many dentists are there in New York?33 answers | 36.7k views
- See Estimation PM Interview Questions
Top Google interview questions
- How would you improve Google Maps?53 answers | 228k views
- A metric for a video streaming service dropped by 80%. What do you do?50 answers | 135k views
- Estimate the number of Uber rides.30 answers | 51.3k views
- See Google PM Interview Questions
Top Estimation interview questions
- Estimate the number of Uber rides.30 answers | 51.3k views
- Estimate the number of bicycles required to start a bike sharing operation in a big city.18 answers | 15.8k views
- Estimate the number of WhatsApp chats occuring in India.14 answers | 13.3k views
- See Estimation PM Interview Questions