![](/img/trans.png)
[英]Reading a file from Google Cloud Storage with XLRD (python)
[英]Reading PDF from Google Cloud Storage
我目前在 Google Cloud Storage 中有一个带有 .pdf 文件的存储桶,我想将每个 .pdf 文件拆分为多个单页 .pdf 文件。
我只能将文件加载为 BLOB(<class 'google.cloud.storage.blob.Blob'>),我找不到关于如何读取为 PdfFileReader object 的好答案。
Upon "fetching" the object/file from the bucket, you can "keep" it in the cloud function memory as a string (of bytes) or save it into a temp "directory" ( /tmp
) local to your cloud function (the memory (临时目录是从可用于云功能的总 memory 中分配的)。 之后,您可以将数据作为字符串或文件进行处理。 完成处理后,您可能希望将这些文件上传到其他存储桶中。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.