I am working on a project where I have developed a Python code that retrieves the 360° image of a specific point (lat, lon) using the Google Street View API. I used this request to obtain 4 images of the same point but with different headings, and it works well.
!google_streetview --location=45.457872348690394,-73.44886627392344 --heading='0;90;180;270' --fov=90 --save_downloads=/content/
from PIL import Image
import glob
import numpy as np
files= glob.glob('/content/gsv_*.jpg')
list_images= []
files.sort(key=lambda f: int(''.join(filter(str.isdigit, f)))) # rangement dans le bon ordre
for f in files:
print(f)
image = Image.open(f)
#image.show()
list_images.append(np.array(image))
temp= np.hstack(list_images)
Image.fromarray(temp).show()
**Is the Google Street View API billed per request or per image (in my case, I sent a single request but obtained 4 images) ? ** Is there any other method through which I can directly obtain the 360° images?