【发布时间】:2017-07-30 19:42:46
【问题描述】:
如何从另一个 Lua 脚本中运行带有用户指定参数的 Lua 脚本?
下面的代码可以工作吗?其中“content_image”是我在“deepdream.lua”脚本中指定的输入图像(保存到图像文件或仍在脚本中),“output_image”是我想要的“deepdream.lua”脚本的输出在我的 Lua 脚本中使用。
dofile("deepdream.lua -content_image content_image -output_image output_image")
我想在另一个 Lua 脚本中运行的脚本可以在这里找到:https://github.com/bamos/dream-art/blob/master/deepdream.lua
【问题讨论】:
-
os.execute("th deepdream.lua -content_image content_image -output_image output_image")
标签: command-line lua deep-dream