我正在用python编写一个使用gs的脚本,但是我无法从gs获得完整的输出。下面是一个最小的python代码:
import subprocess
filename = "bw_dataset"
output = subprocess.Popen(["gswin64c.exe", "-o nul -sDEVICE=bbox", filename + ".pdf"], stdout = subprocess.PIPE, stderr = subprocess.PIPE).communicate()[0].decode()
print(output)
如果我在终端(windows)中运行该命令,我会得到一些%%BoundingBox
和{
{py>但是,^从上面的脚本返回:
因此边界框信息丢失。我如何将其存储在变量中?在
目前没有回答
相关问题 更多 >
编程相关推荐