I am using Dash in Amazon Web Services. I would be very happy to have some hints on how to load data from a S3 bucket for my Dash App. I was thinking about using Boto3, but I am not sure if this provides a solution without saving the file first to local disk, which I do not want. Thank you very much in advance for your suggestions !
There should be a method in boto3 to download without saving to disk if I remember right. Otherwise you could put cloudfront in front of the bucket and load with requests.
import pandas as pd
from botocore.client import Config
client = boto3.client(
obj = client.get_object(Bucket=‘yourbucket’, Key=‘yourkey’)
df = pd.read_csv(io.BytesIO(obj[‘Body’].read()))