# How to generate a file full of image in one time, inset of one image at each time?

**URL:** <https://discourse.julialang.org/t/how-to-generate-a-file-full-of-image-in-one-time-inset-of-one-image-at-each-time/60816>\
**Category:** New to Julia\
**Tags:** question\
**Created:** [May 9, 2021, 8:39am UTC](https://discourse.julialang.org/t/how-to-generate-a-file-full-of-image-in-one-time-inset-of-one-image-at-each-time/60816 "2021-05-09T08:39:12Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![assia855](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/assia855/32/22845_2.png) [@assia855](https://discourse.julialang.org/u/assia855)\
**Post date:** [May 9, 2021, 8:39am UTC](https://discourse.julialang.org/t/how-to-generate-a-file-full-of-image-in-one-time-inset-of-one-image-at-each-time/60816/1 "2021-05-09T08:39:12Z")

</div>

Hello community,

DISKS=get(Array,read(FitsImage, “DISK/Int\_a=1.5\_incl=0.0\_pa=0.0\_e=0.0\_wave=900.fits”));

I have this code. I would like inset of given to julia just one image to execute. I would like to give it a file and to execute all the images inside of it. please help the newbie.

Thanks in advance.

---

<div class="post-metadata">

**Author:** ![gustaphe](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gustaphe/32/18174_2.png) [@gustaphe](https://discourse.julialang.org/u/gustaphe)\
**Post date:** [May 9, 2021, 8:54am UTC](https://discourse.julialang.org/t/how-to-generate-a-file-full-of-image-in-one-time-inset-of-one-image-at-each-time/60816/2 "2021-05-09T08:54:45Z")

</div>

I’m not sure what you’re asking, but [is FITSIO.jl what you’re looking for?](https://github.com/JuliaAstro/FITSIO.jl)

---

<div class="post-metadata">

**Author:** ![assia855](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/assia855/32/22845_2.png) [@assia855](https://discourse.julialang.org/u/assia855)\
**Post date:** [May 9, 2021, 9:27am UTC](https://discourse.julialang.org/t/how-to-generate-a-file-full-of-image-in-one-time-inset-of-one-image-at-each-time/60816/3 "2021-05-09T09:27:38Z")

</div>

Thank for your feedback. I trying to generate a database. With the line that i shared I just can generate one image at each execution. I would like to give to the code a file and he generate for me a lot of image at once.

---

<div class="post-metadata">

**Author:** ![gustaphe](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gustaphe/32/18174_2.png) [@gustaphe](https://discourse.julialang.org/u/gustaphe)\
**Post date:** [May 9, 2021, 9:56am UTC](https://discourse.julialang.org/t/how-to-generate-a-file-full-of-image-in-one-time-inset-of-one-image-at-each-time/60816/4 "2021-05-09T09:56:21Z")

</div>

By “generate” you mean “read from file”, yes? And you have a FITS file containing many images which you want to read in at once? Then FITSIO is what you want.

Read the file in to a FITSIO object, then loop through the images in that object. I can’t really be more specific than that, because I haven’t heard of the format before today, but I think the documentation for that package should get you started.

---

<div class="post-metadata">

**Author:** ![assia855](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/assia855/32/22845_2.png) [@assia855](https://discourse.julialang.org/u/assia855)\
**Post date:** [May 9, 2021, 10:50am UTC](https://discourse.julialang.org/t/how-to-generate-a-file-full-of-image-in-one-time-inset-of-one-image-at-each-time/60816/5 "2021-05-09T10:50:06Z")

</div>

thank you
