ansys / pydpf-post

Data Processing Framework - Post Processing Module
https://post.docs.pyansys.com
MIT License
43 stars 10 forks source link

Get stresses from simulation #233

Closed GuillemBarroso closed 1 year ago

GuillemBarroso commented 1 year ago

Fix #232.

Changes proposed in this PR:

Things to be improved:

Several things can be improved in this PR, although I think it would be better to do it in separate PRs once this one is merged.

image

Instead, it should be displayed as:

image

codecov[bot] commented 1 year ago

Codecov Report

Merging #233 (6e37a7e) into post_refactor (89fdadf) will increase coverage by 3.57%. The diff coverage is 86.36%.

@@                Coverage Diff                @@
##           post_refactor     #233      +/-   ##
=================================================
+ Coverage          74.89%   78.46%   +3.57%     
=================================================
  Files                 30       30              
  Lines               1665     1709      +44     
=================================================
+ Hits                1247     1341      +94     
+ Misses               418      368      -50     
MaxJPRey commented 1 year ago

Things to be improved:

Several things can be improved in this PR, although I think it would be better to do it in separate PRs once this one is merged.

  • Improve print of DataObject and Field. Right now, the prints have references to FieldsContainer and Fields. This should be hidden in PyDPF-Post (the users of Post should not have to know what are the Field or FieldsContainer objects).
  • Display component of the field ("X", "XZ", etc ) in plot's colorbar. Right now only the field name (displacement, stress) is shown.
  • Expose displaying the available named selections in Simulation object.
  • For transient solutions, I added some lines in simulation.py in order to return all time steps when no time_scoping is specified. However, this makes the DataObjet to have integer times instead of the actual time step values, see image below.
  • For transient simulations, the user should be able to select time steps using time values (float) and not only step number (int).

@GuillemBarroso I agree with your suggestions. Indeed this can be done in separate PRs.

PProfizi commented 1 year ago

Closing as stale