julia - 在IJulia中使用for循环时如何显示图像?

标签 julia ijulia-notebook

我想使用 Image.jl 在 Jupyter 中显示图像。 doc说:

If you're using the IJulia notebook, images will be displayed automatically.

Julia code for the display of images can be found in ImageView. Installation of this package is recommended but not required.

但我没能找到任何方法来自动在 for 循环中显示图像。下面的代码是一个示例:

using Images

for i=1:10
    convert(Image,rand(100,100))
end

我猜想在 IJulia 中存在一个未记录的绘制图像的函数,可以显式调用该函数来显示那些隐藏的结果。提前致谢! @索利

最佳答案

您需要使用display函数,这是IJulia使用的,您可以在Multimedia I/O中找到它的文档。 Julia 手册的部分。

enter image description here

关于julia - 在IJulia中使用for循环时如何显示图像?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32752976/

相关文章:

csv - Julia TimeSeries 包中的 Readtimearray 函数

julia - Julia 中两个向量的笛卡尔积

metaprogramming - 消除Julia元编程中的各种引用机制

julia - Julia中的@ code_native,@ code_typed和@code_llvm有什么区别?

python - Julia:用数组中的字符串替换数字

path - Julia :尝试设置值时未定义 JULIA_LOAD_PATH

使用 nbconvert 将 Julia DataFrames 格式转换为 pdf

r - python 2、julia 和 R 内核已死,但 jupyter (ubuntu) 中的 python 3。怎样才能回到正常的环境?

julia - 在 Julia 中使用 DataFrame 生成 15000 行 x 37 列的表时出现问题

julia - 如何轻松检查Julia语言中嵌入函数的实现?