Acquisition type restricted charts for CT
As part of the changes to charts for release 1.0, and the removal of the acquisition type tick boxes in the filters as part of ref #856, the feature to show only acquisitions of a specific type when creating acquisition level charts has been removed.
This issue is to remind us to re-implement the feature in the future if it seems desirable.
Comments (26)
-
reporter -
I think this needs adding for version 1.0. My Canon systems use the same acquisition name for stationary acquisitions as well as spiral or axial acquisitions within the same study. This makes the median CTDI or DLP chart values a bit meaningless.
-
- changed milestone to 1.0.0
-
The acquisition types that we need to be able to filter CT acquisition chart data on are:
- Sequenced Acquisition (“Axial”)
- Spiral Acquisition (“Spiral”)
- Constant Angle Acquisition (“Localiser”)
- Stationary Acquisition
- Free Acquisition
The acquisition type is found via the
ct_acquisition_type_id
in theCtIrradiationEventData
table, which relates to theid
column in theContextID
table. -
I think I’m going to implement this by:
- adding a boolean
UserProfile
field for each CT acquisition type in the CT chart options - including the CT acquisition type in the list of
name_fields
when an acquisition-level CT chart is chosen (around line 479 ofviews_charts_ct.py
) - adding code to
views_charts_ct.py
to filter the contents of the Pandas data frame to keep only the required acquisition types before the chart data is calculated (after line 521, and before line 532). May be able to use something like this example: https://stackoverflow.com/questions/43269548/pandas-how-to-remove-rows-from-a-dataframe-based-on-a-list)
- adding a boolean
-
-
assigned issue to
-
assigned issue to
-
Implemented acquisition type restrictions for acquisition-level CT charts. Refs issue
#877→ <<cset d646ee6737a7>>
-
Including all acquisition types in the CT tests. Refs issue
#877→ <<cset 2141f89a318a>>
-
Ran black. Refs issue
#877→ <<cset c69615a543ab>>
-
Addressing some Codacy issues. To try and reduce duplication I have refactored various bits of chart form processing code that is common between the modality-specific views files and views_admin.py. Refs issue
#877→ <<cset 4624c461851d>>
-
Addressing some Codacy issues: reordering imports in the modality-specific views files. Refs issue
#877→ <<cset 5c5a975fc108>>
-
Adding a check for empty data frame for chart types where this wasn't already being done. Refs issue
#877→ <<cset fbf2b72301cf>>
-
Making reference CT acquisition charts lower case if set in the user profile. Refs issue
#877→ <<cset 5739f0ebb7b0>>
-
Adding Cone Beam acquisition option for filtering CT acquisition-level chart data. Refs issue
#877→ <<cset b0d2d9870fc9>>
-
Using code values and code meanings to match required CT acquisition types, rather than just the code meanings. Refs issue
#877→ <<cset 5d57b86ccec1>>
-
Ran Black. Refs issue
#877→ <<cset c593d522b598>>
-
Added custom line to empty data chart message so that for CT acquisition charts we can warn the user that no acquisition types are selected. A question: should I be excluding zero values when calculating bar charts and box-plots? Are we ever interested in zero values being included? These chart types may be used for things like compression force at some point, where zero values may be of interest. Refs issue
#877→ <<cset 8bd817cbfaa0>>
-
Added missing return component for frequency charts if they are empty. Refs issue
#877→ <<cset 576bded5360a>>
-
Making the message more friendly. Refs issue
#877→ <<cset d102fcb55122>>
-
reporter Adding 'no chart' messages to the translate text. Refs
#877→ <<cset 931f271e840b>>
-
reporter Replacing openremproject.settings with django.conf.settings. Refs
#877→ <<cset 9f9801aca9eb>>
-
Replacing openremproject.settings with django.conf.settings in the other chart view files. Refs
#877→ <<cset 132b23a12f2e>>
-
- changed status to resolved
Merged in issue877acquisitionTypeRestrictedChartsForCT (pull request #449)
Issue877acquisitionTypeRestrictedChartsForCT
Approved-by: Ed McDonagh
Fixes issue
#877→ <<cset 0743e621b6b9>>
-
- changed status to open
The user-selection of acquisition type in the chart options is not correctly looked up when the CT summary page is re-visited.
-
The CT chart options form problem was caused by the required_ct_acquisition_types method making ct_acquistion_types lower case if the user had selected case-insensitive categories. This broke the form initialisation because the lower-case values don't match any of the expected strings. The required CT acquisition types are now made lower case (if necessary) just before they are used to exclude unwanted acquisitions in the DataFrame, resolving the problem. Refs issue
#877→ <<cset 0076520bdf3b>>
-
- changed status to resolved
Merged in issue877FixAcquisitionTypeChartOptionForCT (pull request #456)
The CT chart options form problem was caused by the required_ct_acquisition_types method making ct_acquistion_types lower case if the user had selected case-insensitive categories. This broke the form initialisation because the lower-case values don't mat
Approved-by: Ed McDonagh
Fixes issue
#877→ <<cset e30205a32da2>>
- Log in to comment
Removing tick box acquisition type filter docs. Refs
#856. Chart consequences documented in new issue ref#877→ <<cset 188ff683a3f4>>