-
Couldn't load subscription status.
- Fork 23
Creating png images from raw data
Ct scan images are usually created in a raw format. But MOOSE is not supporting this format.
Currently, only one type is fully supported by MOOSE Image Reader, .png files.
This is why we show you in REDBACK some small converter scripts that can help you with the files conversion. You can then [create a mesh from this stack of images](Creating meshes from Ct scan images).
The file is called raw_to_png.py and is located in REDBACK's folder scripts.
You need to open the file and put the name of your input file on this line:
input_filename = os.path.join('input_files,'CP10_L40.raw')
Your input file should be put in in your working directory in a folder called input_files.
To execute the script, type in the terminal in your working directory:
python raw_to_png.py
This will create the png images in the folder output_files located in your working directory.
The file is called dat_to_png.py and is located in REDBACK's folder scripts.
You need to open the file and put the name of your input file on this line:
input_filename = 'pack.dat' #300x300x300
Note: This file processes a 3D image of size 300x300x300. You will need to modify this file is the size of your image differs
Your input file should be put in in your working directory.
To execute the script, type in the terminal in your working directory:
python dat_to_png.py
This will create the png images in your working directory.
REDBACK: Rock mEchanics with Dissipative feedBACKs