embodiments of this invention focus on ‘ twitches ’: abrupt motions between otherwise comparatively stable positions , as opposed to periodic motions like the beating heart ( where the practice of gating is widely used : data is combined from different times showing the same phase of the cycle to form composite images ). although couched in the context of motion the method is driven by the temporal self consistency of the data and , therefore , potentially has applications beyond twitch detection that will be discussed later . computation of a measure of local self - consistency of the raw pet emission data using some statistical model ( and any necessary assumptions ) that allows behaviours of interest to be identified as features in the time - series plot of the local self - consistency wherein : ‘ local ’ can be defined in any temporal topology , and restricted to some or all of the scanners field of view ‘ behaviours ’ refers to those of the radio - tracer distribution and may be a consequence of the subject &# 39 ; s anatomical motions or physiological action upon the tracer ‘ features ’ referrers to any effect , or combination of effects , on the time - series plot that is predictable given the chosen sense of ‘ local ’, the statistical model and assumptions and behaviours of the tracer distribution , and the computation is performed by systematically extracting local subsets of the scan data and calculating the joint likelihood ( or surrogate such as log joint likelihood ) using the chosen statistical model and assumptions to form the time - series plot of the local self - consistency . in an embodiment of the invention , the method involves assessing the local self - consistency of the data over time in terms of the statistical properties of the pet data . the radioactive decay of the tracer means that the raw sinogram data is well modelled by a poisson distribution : the counts for any bin of the sinogram , during a specified interval , can be described as a poisson variable with a parameter determined by the level of activity along the corresponding line of response . this allows the local likelihood of the data to be estimated for every time during the scan — assuming that there is a constant emission pattern . the intuition is that sudden motions would change the distribution , causing the likelihood to change . using this statistical measure of local self - consistency the scan can be split into segments that are free from sudden changes . this poisson distribution model of the raw data is in contrast to , for example , trying to use reconstructed images , particularly from the iterative methods popular for their better image quality , which makes modelling the statistical properties of the image very difficult . using the poisson - like distributed raw data gives an answer directly related to the physics and processing involved in the emission events and subsequent sinograms from the list data , obtaining a more “ real ” measurement than would be possible from reconstructed methods . for example , the decay of typical radioactive tracers is poisson - like . the result is that the correlation with the model is usually so good that any deviation or abnormality is likely to be a detected event , rather than noise or error . the method of this embodiment can be seen in two aspects : the first is processing the list mode data to generate the ‘ likelihood plot ’, the second is to identify the significant features in the likelihood plot corresponding to the twitches and so segment the scan into frames of self - consistent data ( each corresponding to a single pose ). fig2 provides a schematic overview of a method according to an embodiment , illustrating how for a subject ( 202 ) two windows of list mode data ( 204 ) are histogrammed into sinograms ( 206 ) and their joint likelihood computed ( 208 ), with twitches ( 210 ) evident as a drop in the likelihood under a hypothesis that there is a common tracer distribution between the two windows . the data can then be divided ( 212 ) on this basis . the first aspect may be more fundamental , the second is a step for using the first to solve the twitch detection problem . for a given point during the scan adjacent ‘ windows ’ of data are histogrammed to produce two sinograms . under a null hypothesis that there is a single emission pattern underlying the data , there should be a single set of poisson parameters ( one for each bin of the sinogram ) that fits both the sinograms . for each bin , the parameter that makes the counts observed in the two sinograms most likely is the mean of the two counts ; this follows from maximising the joint likelihood expression ⁢ p ⁡ ( s a [ θ , r ] & amp ; ⁢ ⁢ s b [ θ , r ] ) = λ [ θ , r ] ⁢ ( s a [ θ , r ] + s b [ θ , r ] ) ⁢ ⅇ - λ [ 0 , r ] s a [ θ , r ] ! ⁢ s b [ θ , r ] ! ⁢ ⁢ h ⁢ ⁢ 0 ⁢ : ⁢ ⁢ λ [ 0 , r ] = s a [ θ , r ] + s b [ θ , r ] 2 equation ⁢ ⁢ 1 where s a represents the counts observed in the sinogram bin at projection angle ( theta ) and radial offset ( r ) from the ‘ after ’ window ; s b likewise but from the ‘ before ’ window . lambda is the poisson parameter and ho the no motion hypothesis . given these parameters , the joint likelihood of the two sinograms can be computed on a bin - wise basis . in light of the very small numerical values and large number of sinogram bins it may be difficult to compute the overall joint likelihood of the two sinograms ( the product of the bin - wise joint likelihoods ) because the value falls below the limits of numerical precision . instead , the sum of the bin - wise log joint likelihoods is computed . this is monotonically related to the sinogram - wide joint likelihood and therefore serves as a good surrogate . ⁢ p ⁡ ( s a & amp ; ⁢ ⁢ s b ) = ∏ [ θ , r ] ⁢ p ⁡ ( s a [ θ , r ] & amp ; ⁢ ⁢ s b [ θ , r ] ) ⁢ ⁢ log ⁢ ⁢ p ⁡ ( s a & amp ; ⁢ ⁢ s b ) = ∑ [ θ , r ] ⁢ log ⁢ ⁢ p ⁡ ( s a [ θ , r ] & amp ; ⁢ ⁢ s b [ θ , r ] ) equation ⁢ ⁢ 2 where s a and s b refer to the combined observations of all the elements of the ‘ after ’ and ‘ before ’ sinograms . this calculation is repeated for all times during the scan , producing a ‘ likelihood plot ’— strictly ‘ log - likelihood ’— that measures local self - consistency ( under the - no - change - in - emission - pattern hypothesis ). near times when the underlying pattern of emissions does change , e . g . because of a motion , the pattern of the counts being recorded in the sinograms will become different from each other , causing the log - joint - likelihood to fall . the scan can then be split into sections based on these local minima . the likelihood plot is influenced by two choices : the length of the windows histogrammed together to form the two sinograms and the temporal resolution , the increment with which the windows are stepped through the duration of the scan . the effect of the two windows rolling past a twitch is the ‘ v ’ shaped minimum as would be expected from the assumption of a constant emission pattern not being valid . however , the baseline likelihood in the two poses may not be the same : the re - distribution of counts between different sinogram bins that occurs as a result of the twitch can mean the ‘ baseline ’ joint likelihood is different thereafter . consider a point source at the centre of the scanner &# 39 ; s held of view . all ( true ) counts will be recorded in one column ( radial offset co - ordinate ) of the sinogram . once the point moves off centre the counts will be observed in many columns ( although which one depends on the sinogram row — projection angle ). the result is that the same number of counts is spread over many bins and so the poisson distribution for each bin is different , causing the baseline shift . it follows that the ‘ v ’ shape from the two windows rolling past a sudden change is compounded with a progressive change in the baseline level , centred on the twitch time , as more of the new data with its new baseline level is considered by the windows . the relative magnitudes of the baseline change and the minimum control the overall behaviour ranging from a pure ‘ v ’ to ( almost ) perfect slope , with the minimum becoming progressively more asymmetric between the two . midway between the extremes the minimum disappears : one side of ‘ v ’ is completely cancelled by the change in baseline level , this results in a two part slope between the two levels ( one part is where one side of the ‘ v ’ reduces the slope from the baseline change ; the other reinforces the other part ). however , the known width of the windows means that there is some prior knowledge of the shape of the ‘ minimum ’ that will prove useful in identifying the features of the likelihood plot corresponding to motions in the second half of the method . fig3 illustrates the variations that occur from the interaction of these two phenomena , the varying results of the interaction of a ‘ v ’ shaped minimum and a change in baseline levels . the vertical marks ( 200 ) show the twitch time and the extent ( 202 , 204 ) of the before and after windows around the true twitch time ( 100 s ). examples are given of a deep v ( 206 ), shallow v ( 208 ), and a slope ( 210 ) between two baseline levels . this example is for an instant change between two perfectly stable positions ; real motions will usually exhibit further variations in the ‘ features ’ that occur in the likelihood plot from the non - instant motion , other motions ( like the beating heart ) and tracer kinetics . other effects warranting consideration include the corrections normally applied to scanner data such as scatter correction , attenuation correction , detector normalisation , delayed window subtraction ( randoms correction ). it is usually important to preserve the accuracy of the poisson model and therefore corrections should not be applied . scatter , attenuation and normalisation are not problems themselves — both phenomena can be incorporated into the poisson model ( scatter provides alternative routes from the location of a decay to the detectors , attenuation just means some fraction are not detected , as with the limited sensitivity of the detectors ). motion causes the scatter pattern to change as well , which will be factored into the calculation of the likelihood plot . with most motions the attenuation will move with the tracer distribution , and so can be ignored in this context — think of the effect of attenuation as a change in the tracer concentration . motions where this does not hold ( e . g . blood flow , or the attenuation from the bed ) may still produce a variation in pattern of counts observed . variations of detector sensitivity and field of view produce characteristic patterns on the sinogram , e . g . the diagonal grid from the gaps between the rectangular blocks of crystals arranged around the circular bore of the scanner . as these effects are to do with the scanner , not the subject , motion will cause the pattern of counts to change ‘ behind ’ them . this will influence the amount of change that a motion has on the overall sinogram . the effect could be positive ( consider a small hot region of the sinogram suddenly disappearing behind the diagonal grid ) or negative ( the parts of the sinogram exhibiting significant variation with motion being obscured by the grid ). fig4 is a selection of images of motion of a mouse . the top row images show coronal projections ( 402 , 404 ), illustrating displacement and ( marker 406 ) the cross section for which the sinograms in the second row ( 408 , 410 ) are shown . note the change in the sinogram due to the motion ( other effects like trace kinetics are negligible ), scatter ( as faint counts in the sinogram outside the main band , e . g . those in the rectangle 412 ) and the diagonal grid pattern ( 414 ) from the crystal block gaps . the effect of motions on randoms is more difficult to model , but their correction requires subtracting a delayed - coincidence window , and this subtraction certainly appears to violate the poisson model , so for certain embodiments including randoms is the best course of action . one of the factors that exhibits a strong link to the joint log likelihood computed is the average number of counts in the bins . the overall decay of the tracer during the scan means that the rate of emissions , and therefore observed counts , falls as the scan progresses . this means that , for a fixed window width , the expected number of counts in the windows will fall as the scan progresses . this results in a systematic drift of the likelihood upwards with time . to correct this requires ensuring that there is a constant expected number of counts in the before and after sinograms . this can be achieved by adjusting the widths of the windows based on the time within the scan . specifically , by lengthening the windows , the number of counts will increase and thus compensate for the falling count rate . if the width of the window is chosen correctly , the net result will be a constant expected number of counts . for tracers with short half - lives ( short relative to the window width ) there will also be a need to correct the decay between the before and after windows . the strategy for this correction is exactly the same , the only difference being that the widths of the ‘ before ’ and ‘ after ’ windows are both chosen adaptively rather than picking a single average width for both windows . given that it is simple , it makes sense to do both corrections anyway . radioactive decay means that the count rate will fall exponentially , so it is easy to choose the window widths for some given time . the window widths are set as some function of the time the expected number of counts in each of the windows can be found by integration . by setting the result of these integrals ( one for each window at a given point in time ) to be a target number of counts the following equations gives the width of the windows required to achieve that number of counts . window ⁢ ⁢ widths ⁢ ⁢ in ⁢ ⁢ terms ⁢ ⁢ of ⁢ ⁢ target ⁢ ⁢ count ⁢ ⁢ number ⁢ ⁢  ⁢ w b ⁡ ( t ) = 1 λ ⁢ ln ⁡ ( λ ⁢ ⁢ c * n 0 ⁢ ⅇ λ ⁢ ⁢ t + 1 ) ⁢ ⁢ w a ⁡ ( t ) = - 1 λ ⁢ ln ⁡ ( 1 - λ ⁢ ⁢ c * n 0 ⁢ ⅇ λ ⁢ ⁢ t ) equation ⁢ ⁢ 3 where i is the reciprocal of the half life , c * is the target number of counts , n 0 is the initial count rate . for convenience , one can specify the target number of counts in each window in terms of a duration and the initial count rate . that is to say , instead of choosing n counts per window one can specify a hypothetical window width in seconds which corresponds to having windows of that width , assuming that the count rate were to be constant , matching the average count rate over the duration of the scan . the average count rate can be deduced from the exponential decay behaviour , provided the initial count rate and the duration of the scan are known . substituting for the target count number in the expressions for window width gives the two required functions , which conveniently do not need the initial count rate to be measured ( the half life is known from the tracer , but the activity depends on the age of the tracer , amount injected , et al . ): window ⁢ ⁢ widths ⁢ ⁢ in ⁢ ⁢ terms ⁢ ⁢ of ⁢ ⁢ an ⁢ ⁢ average ⁢ ⁢ ‘ timescale ’ ⁢ ⁢ ⁢ w b ⁡ ( t ) = 1 λ ⁢ ln ⁡ ( w * ⁡ ( 1 - ⅇ - λ ⁢ ⁢ t ) ⁢ ⅇ λ ⁢ ⁢ t + 1 ) ⁢ ⁢ w a ⁡ ( t ) = 1 λ ⁢ ln ⁡ ( 1 - w * ⁡ ( 1 - ⅇ - λ ⁢ ⁢ t ) ⁢ ⅇ λ ⁢ ⁢ t ) equation ⁢ ⁢ 4 where lambda is the reciprocal of the half life , w * is the timescale ( window width at average count rate ) and t is the overall duration of the scan ( the scan from 0 to t defined ‘ average ’ count rate ). the decay correction method can be considered as a non - uniform mapping between ‘ real time ’ and the temporal space in which the windows of the twitch detection are considered — specifically at the start of the scan less ‘ real time ’ is mapped to each unit of ‘ twitch detector time ’ than at the end of the scan . an alternative to dilating windows , as described above , is to decimate the data so as to standardise the count rate throughout the scan . if the above strategy is considered as modifying time to ensure a constant count rate , then this strategy would be considered as changing the data to achieve the equivalent result . this has the obvious disadvantage of requiring data to be discarded from the early sections of the scan in order to reduce the count rate to match the minimum count rate encountered at the end of a scan . this drawback is particularly acute for the early sections of dynamic studies , when the pharmacokinetics of the tracer are fast , and the exact variation is very important to the study . this is also the time when the need to discard data would be greatest . dilating the windows has an equivalent sacrifice in that the effective timescale is the increase as the scan progresses . segmenting the likelihood plot ( and hence the scan ) into sections is a more open problem : there are many ways of finding ‘ features ’ in time series data and the second - order effects ignored so far ( non - instantaneous motion , other smaller motions and tracer kinetics ) will require that this second half to the method be investigated in detail when it comes to implementation . due to the changes in baseline level a simple threshold will likely not be sufficient . furthermore , the compounding of the slope between baseline levels and the ‘ v ’ shape makes it a particularly difficult type of feature to accurately locate — the interaction will introduce a bias . for the purposes of demonstrating the benefits of the likelihood plot a two - stage , non - iterative scheme was used . the first stage is based on the local variance that will find either a ‘ v ’ shaped minimum or a slope . the second stage interoperates the prior knowledge of the feature ( the combined ‘ v ’ and slope ) to refine the first stage estimate . fig5 illustrates the combined two stage segmentation process . the top plot shows the likelihood plot ( i ) and the local variance ( ii )— the latter has been scaled to fit on the same axes . the peak of the local variance — and thus the first stage estimate — is marked ( iii ) along with the true twitch time ( 100 s ) and window extents for that time ( iv ). the baseline component ( v ) is then estimated from the mean of two regions like ( vi ), one either side of the first stage estimate . on the bottom plot : the estimated baseline component is removed , leaving ( vii ) and a minimum sought in the region around the first stage estimate ( viii ). this minimum is the second stage estimate ( ix ). note that the extraneous data ( x ) could have made the second estimate worse , hence only a minimum on the correct side — the direction of the bias in the first stage is known — of the first estimate would be accepted . window shapes : before and after windows could be defined by any windowing function ( in time ), not just the rectangular function as used above . this relies on correctly scaling the counts within windows and also extend to asymmetric windows . window configuration : rather than ‘ before ’ and ‘ after ’ each time point one window could be ‘ at ’ the time point and the other fixed at some point , e . g . the start of the scan ), or the second window an average one for the some part of the scan &# 39 ; s duration , a gap could be introduce between the two windows or there could be some overlap between the windows . marginal implementation : instead of there being an implicit histogramming step the marginal effect on the overall likelihood plot could be computed for each coincidence recorded in the list mode file ( windowing may not be required at all ). regional implementation : only coincidence events possibly originating within a chosen region of the scanners field of view are considered . tracer kinetics correction : tracer kinetics known a priori ( especially the drop in activity due to the isotope &# 39 ; s half life ) could be corrected for by scaling the observed counts to different degrees over the course of the scan . alternative statistical models : although the poisson model is felt to be the only correctly justified one , it is possible that a similar plot could be formulated using some alternate model . alternative null hypothesis : the assumption that there was no motion could be changed and an alternative likelihood plot formulated in which motions would appear , although as different features . hypothesis testing : compare two likelihoods formed using different hypothesise by considering their ratio or some other form of hypothesis test , e . g . a comparison of a no - motion assumption in the choice of the poisson parameter with the assumption that there was a motion . variation of the sinogram resolution : list mode data record the crystal coordinates of the coincidences . there is a conversion from these addresses to sinogram coordinates , as several crystal pairs may count to the same sinogram bin . how this conversion is done depends of the configuration of the sinogram and could be varied — e . g . having fewer bins , and therefore less spatial information , but more counts in each bin . likewise the setting for maximum ring difference and span during 3d acquisition . varying the construction of the sinogram would alter the resulting likelihood plot . time of flight information : this could be incorporated , for instance , by adding another dimension to the sinogram for bins along each line of response . this would increase the resolution of the sinogram and mean there were fewer counts in each bin . note that unlike the non - tof bins , membership of bins in this new time - difference dimension could be considered fuzzy . any means of identifying features in the likelihood plot should be considered , along with any pre - processing methods applied to the likelihood plot before the motion features are sought . note that real motions , especially non - instant motions , may well not fit the theoretical ‘ v ’ plus slope model . in particular , a multi - scale approach to feature identification should be considered . fig6 illustrates a set of likelihood plots generated using a marginal implementation , with decay correction , at a range of timescales . note the variety of the features corresponding to motions and the variation with timescale ( window width in seconds at average count rate ). the vertical lines ( 602 ) indicate times that motions were caused . as the likelihood plot is a measure of the local self - consistency of the data ( the sense of local being defined by the window configuration ) it could be used in several ways other than twitch detection . adaptive framing : dynamic pet scans are often treated as a series of frames , of varying , but predetermined , length . shorter frames are used at the start of the scan when the tracer kinetics are expected to be fastest . the likelihood plot , as a measure of self consistency , could be used to choose an optimal frame length for any point in the scan . intrinsic gating : periodic motions will have an effect on the data &# 39 ; s self consistency , given a suitable timescale ( choice of window width and configuration for example ), especially in a regional implementation of the likelihood plot . this variation could be detected and potentially used to define gates , just as the ecg ( electrocardiogram ) signal is for the heart beat or a chest belt is for breathing . of particular interest would be the ability to gate motion of , say , the diaphragm due to breathing , rather than the breathing itself . ad - hoc gating : by using the correct window configuration ( a chosen reference window and a moving test window ) the similarity between data in any section of the scan and one or more reference sections could be computed and the data from that section of the scan allocated to that gate . consider dual - gating ( breathing and cardiac cycle ): the likelihood that any given window corresponds to the end - diastole / end - expiration phase could be directly estimated . re - acquisition of ac data : implementation in real - time would allow on - line detection of twitches and trigger a reacquisition of the attenuation correction scan , or some anatomical scan to allow accurate registration of the two poses . ( more relevant to pet - mr , this would allow some diagnostic mr to be acquired simultaneously with the pet , rather than continuously using the mr to track motions .) referring to fig7 , the above embodiments of the invention may be conveniently realized as a computer system suitably programmed with instructions for carrying out the steps of the methods according to the invention . for example , a central processing unit 704 is able to receive data representative of medical scans via a port 705 which could be a reader for portable data storage media ( e . g . cd - rom ); a direct link with apparatus such as a medical scanner ( not shown ) or a connection to a network . for example , in an embodiment , the processor performs such steps as generating from a first set of the imaging data an intensity projection line along a specified axis of an image volume of the data , converting the projection line to a monogenic signal and extracting phase information from the signal , calculating a function of the phase information to produce processed phase information , and using the processed phase information to organize the feature of interest in the first data set . software applications loaded on memory 706 are executed to process the image data in random access memory 707 . a man - machine interface 708 typically includes a keyboard / mouse / screen combination ( which allows user input such as initiation of applications ) and a screen on which the results of executing the applications are displayed . it will be appreciated by those skilled in the art that the invention has been described by way of example only , and that a variety of alternative approaches may be adopted without departing from the scope of the invention , as defined by the appended claims . although modifications and changes may be suggested by those skilled in the art , it is the intention of the inventor to embody within the patent warranted hereon all changes and modifications as reasonably and properly come within the scope of his contribution to the art .
in methods and an apparatus for detecting an incident or behavior in a medical image scan of a subject , a list of image data points captured during the scan is obtained , and a scan period of the scan selected . a model for a distribution of list data over the scan period is obtained , the model at least in part based on the list data from the scan period . list data are compared with the model , by calculating a statistical measure of the self - consistency of the list data with reference to the model .