Change microstructure resolution WITHOUT changing Euler angles

165 views
Skip to first unread message

Elise Baribault

unread,
Oct 1, 2021, 7:41:18 PM10/1/21
to dream3d-users
Hi Mike,

A while back I had asked many questions about importing STLs and changing resolutions of microstructures. Now a have a new question, related to changing resolutions.

I have an original DREAM3D file, a 90^2 microstructure, and right now I have three separate pipelines to create three different resolutions (64^3, 128^3, and 256^3). So I go from 90^3->63^3 and 90^3 to 128^3 and 90^3 to 256^3.

 However, now I have an issue of I need to keep the Euler angles consistent between all of the resolutions. Meaning I need to keep the Euler angles and feature ID numbers the same as the original microstructure, only increase voxel resolution.

When I import a DREAM3D file, is there a way to keep the Euler angles and feature IDs the same?

For reference here is the old conversation:

Thank you,
Elise 

Michael Jackson

unread,
Oct 3, 2021, 11:35:08 AM10/3/21
to Elise Baribault, dream3d-users
Dear Elise,
I'm not sure of the pipelines that you are using but if you are
using the "Change Resolution Filter" just uncheck the "Renumber
Features" checkbox and all of the Feature Ids will remain the same. If
I am not understanding your question, do let me know.

PLEASE NOTE: Doing this may make subsequent filters that depend on a
contiguous set of Grain ids that start at zero become unusable, mainly
through DREAM.3D Crashing. :-(
--
mike jackson
> --
> You received this message because you are subscribed to the Google Groups "dream3d-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to dream3d-user...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/dream3d-users/7e0cb9dd-8454-4edc-a5c5-5190e8d7eee2n%40googlegroups.com.

Elise Baribault

unread,
Oct 7, 2021, 4:59:35 PM10/7/21
to dream3d-users
Hi Mike,

Thank you for your reply. I understand what you are saying. I did use the "Change Resolution Filter" and the "Renumber Features" is unchecked. However, I do have a "Match Crystallography" filter, in which  "Euler Angle" are under Created Objects. I believe this is why I am getting different Euler angles each time. However this is not what I want.

I realize the source of my error is likely that in the original pipeline, Euler Angles are not created (which is why my pipeline generates Euler angles after I import the original model). So the original DREAM3D file that creates 67 grains with specific feature IDs, but doesn't assign any orientations. 

I have been passed a texture file that contains Euler Angles for each of the 67 grains (attached). Can I import that into DREAM3D somehow? At the end of my pipeline, I have "Export Los Alamos FFT File" because I need a text file created from the microstructure. This is why I need the Euler angles matched with the specific grain IDs from the texture file. Hopefully this makes sense.. 

Thank you,
Elise

Cu_67_Elise.TEX

Michael Jackson

unread,
Oct 15, 2021, 9:31:00 AM10/15/21
to Elise Baribault, dream3d-users

You should be able to import the texture file using the “Import ASCII Attribute Array” after reading in the model file. That will associate the Eulers from the texture file with each grain. Then you will need to use the filter “Create Element Array from Feature Array” to put the eulers down onto the Cell data so that when you write the FFT File you have an Euler Angle at each cell position.

 

The issue with this approach is that if the feature Ids are NOT contiguous starting from 0 then the second filter that I mentioned will fail (probably outright crash DREAM.3D).

 

 

--

Mike Jackson

Elise Baribault

unread,
Oct 16, 2021, 10:33:32 AM10/16/21
to dream3d-users
Hi Mike,

Thanks for the reply. I tried these filters but am getting an error importing the file. This is what my pipeline looks like, with the input file being a .txt file. Should it be a different format like .csv? I am not sure if the number of components should be the number of rows? The "first line of data" is correct.

Untitled.png

Untitled.png

Thank you,
Elise

Michael Jackson

unread,
Oct 18, 2021, 10:05:17 AM10/18/21
to Elise Baribault, dream3d-users

Dear Elise,

    A few things:

 

+ Looks like your data is floating point data so I would change the data from “signed int 8 bit” to “Float”

+ The “Number of Components” should be 3

+ Looks like the rest should be correct.

 

The filter will attempt to read as many rows from the text file as there are “Tuples” in the particular Attribute Matrix that the DataArray is going to be saved into. From your guess it looks like your text file should have 67 rows of data (not taking the header lines into account).

 

Also, looks like the values are expressed as Degrees. If you are going to do any calculations involving those angles inside of DREAM3D, do not forget to convert them to Radians using the appropriate filter (Just search for the word “Degrees” in the filter list).

 

--

Mike Jackson

 

On 10/16/21, 10:33 AM, "Elise Baribault" <dream3...@googlegroups.com on behalf of ebarib...@gmail.com> wrote:

 

Hi Mike,

 

Thanks for the reply. I tried these filters but am getting an error importing the file. This is what my pipeline looks like, with the input file being a .txt file. Should it be a different format like .csv? I am not sure if the number of components should be the number of rows? The "first line of data" is correct.

 

 

Elise Baribault

unread,
Oct 18, 2021, 3:37:57 PM10/18/21
to dream3d-users
Hi Mike,

Thanks for your suggestions. I am now getting a different error:

Untitled.png

Is there a way I can set the end of the file? Maybe I'm misinterpreting what this error means. Also I added the weights for each grain, so I changed the components to be 4 (4 columns).

A peer suggested I follow this: http://www.dream3d.io/Filters/OrientationAnalysisFilters/WriteStatsGenOdfAngleFile/index.html to convert my .txt file to a different .txt file format. Would this be a better way?

Thanks,
Elise

Michael Jackson

unread,
Oct 18, 2021, 4:28:33 PM10/18/21
to Elise Baribault, dream3d-users

You may have entered one too many rows to be read? Or the delimiter isn’t correct? The file needs to have consistent delimiters throughout the file.

 

--

Mike Jackson

 

On 10/18/21, 3:37 PM, "Elise Baribault" <dream3...@googlegroups.com on behalf of ebarib...@gmail.com> wrote:

 

Hi Mike,

 

Thanks for your suggestions. I am now getting a different error:

 

 

Is there a way I can set the end of the file? Maybe I'm misinterpreting what this error means. Also I added the weights for each grain, so I changed the components to be 4 (4 columns).

 

A peer suggested I follow this: http://www.dream3d.io/Filters/OrientationAnalysisFilters/WriteStatsGenOdfAngleFile/index.html to convert my .txt file to a different .txt file format. Would this be a better way?

 

Thanks,

Elise

 

On Monday, October 18, 2021 at 10:05:17 AM UTC-4 mike.j...@bluequartz.net wrote:

Dear Elise,

    A few things:

 

+ Looks like your data is floating point data so I would change the data from “signed int 8 bit” to “Float”

+ The “Number of Components” should be 3

+ Looks like the rest should be correct.

 

The filter will attempt to read as many rows from the text file as there are “Tuples” in the particular Attribute Matrix that the DataArray is going to be saved into. From your guess it looks like your text file should have 67 rows of data (not taking the header lines into account).

 

Also, looks like the values are expressed as Degrees. If you are going to do any calculations involving those angles inside of DREAM3D, do not forget to convert them to Radians using the appropriate filter (Just search for the word “Degrees” in the filter list).

 

--

Mike Jackson

 

On 10/16/21, 10:33 AM, "Elise Baribault" <dream3...@googlegroups.com on behalf of ebarib...@gmail.com> wrote:

 

Hi Mike,

 

Thanks for the reply. I tried these filters but am getting an error importing the file. This is what my pipeline looks like, with the input file being a .txt file. Should it be a different format like .csv? I am not sure if the number of components should be the number of rows? The "first line of data" is correct.

 

Image removed by sender.

 

Image removed by sender.

Elise Baribault

unread,
Oct 18, 2021, 5:35:10 PM10/18/21
to dream3d-users
Unfortunately, it's still not working.. I know I can take my FFT .txt file and manually change all the angles, but I was hoping for a quicker way. If I manually change the .txt file, is there a filter to import it back to DREAM3D to change resolution? Or would I need to change all the angles for all the resolutions manually?

Thanks,
Elise

Elise Baribault

unread,
Oct 19, 2021, 12:48:51 AM10/19/21
to dream3d-users
Hi Mike,

I was able to get this working. I used "Import ASCII Data", "Combine Attribute Data", and "Convert Angles to Deg or Rad". However...

Now I have a pipeline that generates a microstructure as well as an FFT .txt file that only has the first 67 angle pairs filled in and the rest are 0. The pipeline didn't assign the angles to the specific grains, it only listed the 67 angle pairs in sequential order. I must be missing a step?

Thanks,
Elise

Elise Baribault

unread,
Nov 22, 2021, 10:45:59 PM11/22/21
to Michael Jackson, dream3d-users
Hi Mike,

I was able to work around my error by writing a Matlab script to rewrite the Euler angles of my text files for each resolution.

My final question is now that I have 3 text files in "Los Alamos FFT File" format with the Euler angles, x, y, and z coordinates, grain ID, and phase number, can I re-import the files into DREAM3D and export an xdmf to visualize the 3D microstructure in Paraview? Or do I need to import the text files themselves into Paraview and process there?

Thank you and happy thanksgiving!
Elise

On Wed, Oct 20, 2021 at 2:34 PM Michael Jackson <mike.j...@bluequartz.net> wrote:

Elise,

  I am plowed under getting a proposal written. I’m going to go back through our emails and try and figure out what might be going wrong with your pipeline but I need a bit of time to get that done. I’ll try to get back to you as soon as I can. We might have to setup a virtual meeting so that you can walk me through your workflow so that I can fully understand the end goal of the work.

 

Cheers.

--

Mike Jackson

 

On 10/19/21, 12:48 AM, "Elise Baribault" <dream3...@googlegroups.com on behalf of ebarib...@gmail.com> wrote:

 

Hi Mike,

 

I was able to get this working. I used "Import ASCII Data", "Combine Attribute Data", and "Convert Angles to Deg or Rad". However...

 

Now I have a pipeline that generates a microstructure as well as an FFT .txt file that only has the first 67 angle pairs filled in and the rest are 0. The pipeline didn't assign the angles to the specific grains, it only listed the 67 angle pairs in sequential order. I must be missing a step?

 

Thanks,

Elise

On Monday, October 18, 2021 at 5:35:10 PM UTC-4 Elise Baribault wrote:

Unfortunately, it's still not working.. I know I can take my FFT .txt file and manually change all the angles, but I was hoping for a quicker way. If I manually change the .txt file, is there a filter to import it back to DREAM3D to change resolution? Or would I need to change all the angles for all the resolutions manually?

 

Thanks,

Elise

 

On Monday, October 18, 2021 at 4:28:33 PM UTC-4 mike.j...@bluequartz.net wrote:

You may have entered one too many rows to be read? Or the delimiter isn’t correct? The file needs to have consistent delimiters throughout the file.

 

--

Mike Jackson

 

On 10/18/21, 3:37 PM, "Elise Baribault" <dream3...@googlegroups.com on behalf of ebarib...@gmail.com> wrote:

 

Hi Mike,

 

Thanks for your suggestions. I am now getting a different error:

 

Image removed by sender.

 

Is there a way I can set the end of the file? Maybe I'm misinterpreting what this error means. Also I added the weights for each grain, so I changed the components to be 4 (4 columns).

 

A peer suggested I follow this: http://www.dream3d.io/Filters/OrientationAnalysisFilters/WriteStatsGenOdfAngleFile/index.html to convert my .txt file to a different .txt file format. Would this be a better way?

 

Thanks,

Elise

 

On Monday, October 18, 2021 at 10:05:17 AM UTC-4 mike.j...@bluequartz.net wrote:

Dear Elise,

    A few things:

 

+ Looks like your data is floating point data so I would change the data from “signed int 8 bit” to “Float”

+ The “Number of Components” should be 3

+ Looks like the rest should be correct.

 

The filter will attempt to read as many rows from the text file as there are “Tuples” in the particular Attribute Matrix that the DataArray is going to be saved into. From your guess it looks like your text file should have 67 rows of data (not taking the header lines into account).

 

Also, looks like the values are expressed as Degrees. If you are going to do any calculations involving those angles inside of DREAM3D, do not forget to convert them to Radians using the appropriate filter (Just search for the word “Degrees” in the filter list).

 

--

Mike Jackson

 

On 10/16/21, 10:33 AM, "Elise Baribault" <dream3...@googlegroups.com on behalf of ebarib...@gmail.com> wrote:

 

Hi Mike,

 

Thanks for the reply. I tried these filters but am getting an error importing the file. This is what my pipeline looks like, with the input file being a .txt file. Should it be a different format like .csv? I am not sure if the number of components should be the number of rows? The "first line of data" is correct.

 

Error! Filename not specified.

 

Error! Filename not specified.

Michael Jackson

unread,
Nov 23, 2021, 9:12:25 AM11/23/21
to Elise Baribault, dream3d-users

Elise,

    I’ve not tried directly importing an FFT file into ParaView. You might be able to do that and skip DREAM.3D, I would try the CSV reader in ParaView and see what that does. You will probably have to combine all of the files together. Also ParaView really will not help you visualize the Euler Angles in any meaningful way. You could always reprocess back through DREAM.3D in order to generate the IPF Colors if needed and the XDMF files for ParaView.

 

--

Mike Jackson

 

On 11/22/21, 10:45 PM, "Elise Baribault" <ebarib...@gmail.com> wrote:

 

Hi Mike,

 

I was able to work around my error by writing a Matlab script to rewrite the Euler angles of my text files for each resolution.

Error! Filename not specified.

Anthony Rollett

unread,
Nov 23, 2021, 12:05:56 PM11/23/21
to Michael Jackson, Elise Baribault, dream3d-users
Hi
I would trust the dream3d file (with its xdmf) to show you the microstructure.
Now, when you have FFT results then you may need some software to convert the text files to, say, vtk files that paraview can read.

Easier perhaps if you use the parallel MASSIF version?

Tony 


Sent from my iPhone
Reply all
Reply to author
Forward
0 new messages