and Key Terms: Abstract Functional, comfortable prosthetic limbs depend on personalised sockets, currently designed using an iterative, expert -led process, which can be expensive and inconvenient. Computer aided design and manufacturing (CAD/CAM) offers enhanced repeatability, bu t far more use could be made from clinicians’ extensive digital design records. Knowledge -based socket design using smart templates could collate successful design features and tailor them to a new patient. Based on 67 residual limb scans and corresponding sockets, this paper develops a method of objectively analysing personalised design approaches by expert prosthetists, using machine learning: principal component analysis (PCA) to extract key categories in anatomic and surgical variation, and K - Means Clus tering to identify local ‘rectification’ design features. Rectification patterns representing Total Surface Bearing and Patella Tendon Bearing design philosophies are identified automatically by PCA, which reveals trends in socket design choice for differe nt limb shapes that match clinical guidelines. Expert design practice is quantified by measuring the size of local rectifications identified by k-means clustering. Implementing smart templates based on these trends requires clinical assessment by prostheti sts and does not substitute training. This study provides methods for population -based socket design analysis, and example data, which will support developments in CAD/CAM clinical practice and accuracy of biomechanics research. Keywords: Transtibial Amp utation; Prosthetic Limb; CAD/CAM; PCA; K -means clustering; Machine Learning; Statistical Shape Analysis; Image Processing Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice Introduction Prosthetic socket design and fitting is crucial for providing comfortable, stable and functional prostheses that match the shape and biomechanical characteristics of the individual residual limb, distributing the pressure created by ambulatory loading in ways the limb can tolerate without tissue damage [1]. Residual limb shapes, sizes and tissue tolerances vary significantly across the population, so understanding the design objectives to best suit an individual is complex. Conventional approaches to socket fitting rely heavily on the skill of prosthetists, who work from limited objective data. There is a need for evidence to support their design choices so that they can optimise the fit for the individual, and at present this is a highly iterative process [2], [3]. Some iteration will always be required, to accommodate limb volume and shape changes especially in the first year after amputation, but this project’s goal is to reduce the iteration arising from trial and error. Current clinical practice in residual limb shape capture and prosthetic socket desi gn. There is a range of approaches for capturing the shape of a residual limb and generating a corresponding socket design, with shape capture and design often overlapping [4]. Hands -on methods include capturing the limb shape by plaster casting, creating a positive mould, and performing a range of shape modifications known as rectification (carving material off the mould, or building material up), so that a vacuum -formed or composite socket has a desired pattern of limb -prosthesis interface load transfer. The two most common approaches at the transtibial level are known as Patellar Tendon Bearing (PTB) [5] and Total Surface Bearing (TSB) [6]. PTB aims to load preferentially the tolerant tissue sites in the residual limb (including the patella tendon and fleshy zones either side of the anterior tibia and over the calf muscles), and offload more vulnerable sites (including the anterior and distal tibia, the fibula head, and residual limb tip). TSB sockets with elastomeric liners are inten ded to achieve more uniform load transfer across the limb surface, and avoid pressure gradients. Alternatively, several ‘hands -off’ shape capture methods are available, which aim to create uniform load transfer directly in response to the residual limb ti ssues’ compliance under load. Hydrostatic Sockets (HS) are plaster cast over a silicone elastomer liner, non -weightbearing, with pressure applied through compressed air [7], [8] . Pressure casting can also be performed weightbearing; the PCAST approach collects a plaster cast while weightbea ring, suspending the limb inside a cylinder of water [9], and the CIR system uses sand casting under vacuum [10], [11] . These methods are designed to reduce variation and reliance on manual dexterity, but may still require local shape modifications [4]. The family of Computer -Aided Design and Manu facturing (CAD/CAM) technologies are growing in use, typically to create sockets by the PTB and TSB concepts through digital modification of a 3D shape scan file, before carving a foam mould for socket fabrication. CAD/CAM requires the same clinician exper ience and skill as plaster methods, and gives the prosthetist full control over the design whilst preserving a digital record of individual designs, and their practice as a whole. Towards more evidence -based prosthetic socket design Prosthetists have ident ified the need for support in evidence -based socket design to improve socket fit, and this remains part of the International Society for Prosthetics & Orthotics (ISPO) mission and ISPO 50 Charter [12]. Conventionally this employs user feedback, though this is subjective and may be unreliable in people with vascular disease, whos e tissues may be insensate. Technologists have worked towards offering feedback from limb -socket interface stress sensors [1], [13] or predicting pressure, based on socket strain [14] and biomechanical simulations, co mmonly Finite Element Analysis (FEA) [15], [16] . Despite recognising the need for these technologies over two decades ago, and recommendations for their clinical adoption [17], [18] they have not yet reached common use and prosthetists still have the same request for technological support. Socket design and fitting feedback technologies may face barriers to clinical adoption if they are not designed for users with conventional prosthetist -orthotist training, or if they add cost, complexity or inconvenience to the existing clinical pathway. For example, FEA is unlikely to be a dopted if it requires expensive software licenses, a high -performance computer, expensive volume imaging (typically magnetic resonance imaging (MRI)), and a trained biomechanical engineer to build each patient’s model [16]. Furthermore technologies are unlikely to face a warm reception from the clinical community if they are proposed to replace the need for skill and experience, or place any barrier between the clinician and th eir patient. Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice Machine Learning Recently researchers have proposed the use of Machine Learning (ML) to bridge the gap between hands -on socket design and complex software -supported alternatives. Machine Learning is a subset of techniques within Artificial Intelligence (AI), which involves the examination of datasets to find patterns. With ‘supervision’ to link these patterns to some known description or desired outcome, ML can be used for prediction or recommendation, and several applications have been considered for lower limb prosthetics . Sewell et al [14] used artificial neural networks (ANN) to predict socket -limb interface pressures from non - invasive strain measurements in the socket. Here, ML is unobstructive to the patient and clinician and potentially provides informative data, but imposes a workload in training the ANN for each socket. Colombo et al [19] proposed conducting automatic rectification design using an ANN based on a residual limb 3D scan, the person’s weight and desired activity level, and simple tissue ‘tonicity’ -deformatio n relations. The alternative approach considered by biomechanical modellers is optimisation, whereby the socket design is adjusted in order to meet an objective such as minimising limb -socket interface pressure, or soft tissue strain [20]–[22]. Optimisation may be computationally expensive and require modelling knowledge, and ANNs remain limited by their large requirement for training data, which may not be available in prosthetics, and because they a re often effectively black boxes for all except simple problems. Instead, Expert Systems or Knowledge Based Systems are proposed to be suited to the prosthetic socket design problem, as they involve learning to mechanise tasks which humans already perform well. Li et al [23] proposed the Analytic Hierarchy Process decision approach to determine personalised socket design ‘compensations’ based on multiple prosthetists’ experience -based recommendations, and the residual limb’s characteristics. Combining expert knowledge and physica l measurements, Karamousadakis et al [24] used a fuzzy -logic Inference Engine (IE) to convert socket pressure and shear stress measurements and expert prosthetists’ design rules into rectifications for a transfemoral socket design. Using more intuitive methods and incorporating expert knowledge i n design might mean these concepts are closer to the objectives mentioned above, but it remains non -trivial to integrate them with current clinical workflows, requiring minimal additional modelling or sensor complexity and expense. Understanding population and design variation in current prosthetics workflows The idea of learning from CAD/CAM prosthetic design practice was proposed in the 1990s. Lemaire and Johnson [25] presented a method for quantifying and comparing manual rectifications in the commercial CADVIEW CAD/CAM environment, and proposed using these data for education, improving clinical efficiency and consistency, and ensuring CAD/CAM is informed by best -practi ce manual approaches. Torres -Moreno et al created a library of 27 reference shapes for transfemoral socket design in a CAD system, considering combinations of three brim sizes, lengths and profiles (skinny/sparse, average/moderate and fat/bulky), which could be modified interactively [26]. Later, Lemaire et al [27] proposed using averaged modifications as a template for CAD/CAM rectifications, and demonstrated this approach prod uced sockets with equivalent function, comfort and overall satisfaction to manual methods. Recently Fatone et al have used a similar approach to produce templates for the transfemoral NW -FSIV socket [28]. Templates are not in common clinical use for CAD/CAM below -knee prosthetic socket design, though some clinicians use itemised workflows. Improvements in 3D scanning technology and computational power and methods, as well as the increased collaborative work between data scientists and clinicians may now enable these early concepts to be enhanced. More formal populati on-based methods such as Principal Component Analysis (PCA), employed for statistical shape modelling (SSM) can be used to reduce the dimensionality of anatomic variation, allowing identification of the principal, independent ‘modes’ of variation between i ndividuals in a dataset. Population - based modelling approaches have extensive history in orthopaedics and musculoskeletal biomechanics, enabling machine learning to enhance the personalisation of models [29]. Understanding the behaviour of interventions or me dical devices in a representative population sample is compulsory in preclinical trials, and is practical, low risk and low cost in an in silico clinical trial, sometimes using virtual participants. This population -based approach addresses the range of pos sible outcomes and avoids the risk of using near - average patient models that do not adequately represent the full range of results across a population [30]. This approach to capture variations in residual limb size and shape alone was used in superv ised ML by Worsley et al [31] to automatically classify residual limb shapes by their profile, and by Steer et al [32] as a means of providing FEA predictions of limb -socket interface pressure in real time. Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice Motivation We argue that it is inappropriate to fully automate the prosthetic socket d esign process, given the importance of clinical expertise to personalisation. However, we propose that there is benefit in pursuing evidence -based approaches to save time and iteration towards an acceptable socket for each person, learning from experts at each stage (Fig.1). Figure 1. Proposed process overview for developing and using smart templates as part of expert -informed, evidence -based socket design. Instead of automating design at the expense of clinicians, the proposal includes the experts in each stage of development and clinical use. Whilst there are proven conventions in socket design, there is no consensus on the targets for limb -socket rectification sizes, or their spatial pattern. There is also no measure of the clinically observed variability in these parameters. PCA and image analysis methods may allow extraction of quantitative descriptions of the key trends in prosthetic socket design as well as residual limb shape, which might be used in supervised ML to propose initial template designs for a new fitting. Objective As a step towards enhancing prosthetic socket templates using expert clinician design data, this study set out to evaluate supervised machine learning methods trained on a population of resid ual limb 3D scans and their matched, clinician -produced prosthetic socket designs. This research investigated how population - based models of the residual limb anatomic shape and the prosthetic socket design might be built, the key requirements for each, an d whether separate shape and design models might provide higher resolution for machine learning than a combined shape and design model. The data was then inspected to characterise expert socket design following PTB and TSB approaches, and to identify any g eneral trends in socket design for particular residual limb shapes. Methodology Study Design, Approval and Raw Data This study was approved by the University of Southampton’s institutional ethics and research governance office (ERGO, ID 53279), as a retro spective audit of clinical design practice. Inclusion criteria were age of 18 years or above, and transtibial amputation. Sixty -seven participants were selected by random sampling from clinical service provision in the UK. The sample contained 20 females a nd 47 males, mean age 56.9 years (range 19.6 -88.2 years) and mean 4.5 years since amputation (range 0.14 -30.2 years). Participants had a range of activity levels (8 K1, 29 K2, 27 K3, 3 K4) and reasons for amputation (27 dysvascularity, 20 trauma, 11 infect ion, 5 neoplasia, 2 neurological, 2 unknown). 55 had been fitted with a PTB socket, and 12 with a TSB, 40 to their left limb and 37 to their right. For each participant a pair of 3D surface mesh (.stl) files were provided, representing their residual limb scan and the corresponding mould shape for carving to produce a rectified socket. Researchers performing data processing were blinded to participant metadata. Application: Template -Based Socket Design in Clinic Smart Templates might reduce clinician workload in coarse design, and allow expertise sharing...... freeing them to focus their time on higher value - added limb assessment, template personalisation, etc.Interpreting: Supervised Machine Learning for Smart Templates Identify trends in limb shape, socket design and measures of outcomeExperts provide interpretation to identify the meaning of these trends, and how to apply themLearning: Socket Design Data Foundation Digital record of clinical design and outcome history from groups, or a single clinician’s practiceExperts provide consensus upon the key factors in design for limb -socket interaction Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice PCA for Statistical Shape and Design Models Scan pairs were processed using the ampscan open sour ce shape analysis toolbox [33] as a development of a previously published method for non -paired data [34]: • Right sided shapes were mirrored. • The full set of socket shapes were aligned. A vertical superior -inferior translation was applied so that all shapes’ patella tendon rectification was located at z=0, and the shapes’ centroids at the patella tendon level were aligned in the medial -lateral and anterior -posterior axes ( x=0, y=0 ). An internal - external rotation was applied so that the posterior trimline lay parallel with the coronal plane. The sockets’ abduction -adduction and flexion -extension were not changed from the CAD file. • Each l imb shape was aligned with its corresponding socket. Shapes were aligned first by their centroids, then by automatic iterative -closest -point (ICP) surface matching. Where the limb and socket scan shapes deviated considerably, manual alignment adjustments w ere made and checked by two experienced observers (LED, ASD) to ensure prioritised medial -lateral, anterior -posterior and abduction -adduction alignment at the knee, flexion -extension and internal -external rotation alignment at the anterior tibia. Superior -inferior alignment referenced the anterior tibia and patella. • An HC Laplacian smoothing algorithm was applied to remove noise while preserving volume, and the socket shapes were cut at an approximated trimline. • A ~30,000 node mesh was registered onto each of the limb and socket meshes, to allow direct comparison in location of corresponding vertices. • A field of surface vertex normal deviations representing the rectification design was calculated between each limb -socket pair, and plotted according to an acc essible colour map (Fig.2) common to the prosthetics community [25]. (Figure 2). Example limb shapes plotted with rectification design field from aligned, registered sockets, of PTB (top) and TS B (bottom) design approaches. Rectifications are labelled as PT (patella tendon), TC (tibial crest), DAT (distal anterior tibia), D T (distal tip), LP (lateral paratibial), MP (medial paratibial), FH (fibula head), MSC (medial supracondylar), LSC (lateral supracondylar), and PF (popli teal fossa). The images also label the trim line (TL). The shape above the trim line, removed in socket production, is irrelevant to socket -limb load transfer so is masked in yellow Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice • A statistical limb shape model (SLM) using the limb scans as a training dataset was produced by principal component analysis (PCA) using the scikit -learn toolbox1. The mesh fil es were each represented as a column vector: 𝒙=[𝑥1,𝑦1,𝑧1,…,𝑥𝑚,𝑦𝑚,𝑧𝑚]𝑇 (1) where 𝑚 represents the number of nodes in the baseline mesh and 𝑥, 𝑦 and 𝑧 are the vertex coordinates. A vector describing the mean limb shape was calculated by: 𝒙̅=1 𝑛∑𝒙𝑖𝑛 𝑖=1 (2) where 𝑛 represents the number of limbs in the training dataset. PCA by mean -centred Singular Value Decomposition allowed each limb shape to be de scribed by: 𝒙=𝒙̅+∑𝝋𝑗𝒅𝑗𝑐 𝑗=1 (3) where 𝝋𝑗 are eigenvectors corresponding to the 𝑐 Principal Components (PC) or ‘modes’ of the population’s shape variation, and 𝒅𝑗 is a vector of weighting coefficients associated with the eigenvectors to describe each shape’s deviation from the mean . • A statistical design model (SDM) was produced in the same way, but using a column vector containing the socket -limb rectification values 𝑟 at each vertex : 𝒙=[𝑟1,…,𝑟𝑚]𝑇 (4) • Finally, a statistical limb shape and design model (SLDM) was produced in the same way, using a column vector of the limb shape and socket -limb rectification values: 𝒙=[𝑥1,𝑦1,𝑧1,𝑟1,…,𝑥𝑚,𝑦𝑚,𝑧𝑚,𝑟𝑚]𝑇 (5) • The 95% range of population variation in limb shape was estimated by plotting synthetic shapes with weighting coefficients at 𝑑𝑗=±2𝜎 either side of the mean for each mode in turn, where 𝜎 represents the standard deviation of variation. Extremes of (non -parametric) socket design variation were plotted using the 2.5th and 97.5th percentile mode scores. Variations were interpreted by expert observers (DH, EP) . K-Means Cluster Analysis of Localised Rectifications A second methodology was developed to semi -automatically identify particular rectification features using a custom image recognition and classification tool, trained to identify PT, FH, MP, LP and DT rectifications. This involved: • Segmentation: fields of rectification curvature, and combined rectifi cation and curvature from the 67 training datasets (Fig.3a) were mapped onto 224 x 224 -pixel 2D images (Fig.3b) . K-means clustering was applied across all the images to generate up to 90 binarised pixel regions per image (Fig.3c) . • Feature Extraction: The shape of each region was quantified using Histogram of Oriented Gradients (HOG) to compute the edge detection gradient, followed by PCA to reduce the problem dimensionality, with the first 25 components retained (>95% of explained variance). In parallel, t he location of each region was quantified by dividing the original region into a 7 x 7 grid, with the number of pixels for each region in each grid square calculated. Finally, the total pixel count was included. This resulted in a total of 75 features for each region which were then used for classification. • Classification: the features were fed into a second k -means clustering algorithm, which groups the regions generated from the image segmentation. To ensure all groups represented the same features, erroneous clustering was identified through comparison to the average of each cluster. Outliers were identified based upon pixel overlap with the average cluster. Any outlier regions were then moved to 1 https://scikit -learn.org Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice the cluster where they were closest to the average. The cl ustered groups were then visually inspected and related to rectifications of interest, for example, a group which contains the patella tendon bars across all input sockets (Fig.3d). The classified cluster images were then mapped back onto the corresponding 3D shape (Fig.3e) . (a) (b) (c) (d) (e) Figure 3. K -Means Clustering Method for identifying and measuring local rectifications. The socket curvature and rectification maps are taken as inputs (a) and mapped onto 244 x 244 pixel 2D arrays (b). K -means clustering is used to identify regions of pix els representing design features (c). These are clustered, and desired features are classified using their shape and location, labelled (d) , and finally mapped back onto the 3D socket shape (e). Data Analysis The validity of the three PCA models (limb shap e model, socket design model, and combined model) was evaluated and compared. Compactness was assessed by finding the number of modes required to describe 95% of the training population’s variance. Generality was assessed by Leave -One-Out (LOO) testing to identify the required training dataset size. Each training population shape was left out of the statistical model generation and then reconstructed using its weighting coefficients from the complete model, and its root mean squared error (RMSE) of reconstr uction was calculated. A threshold RMSE of 1mm was defined, based on consistency measures of manual rectifications [35], plaster casting and 3D scanning in limb shape capture for socket design [36]. Gross and detailed shape and rectification measures were analysed for the training datas et. The limb lengths were measured from patella tendon to distal tip, and perimeters at the patella tendon and at half and three - quarters of the length. Profile ratios were created between the half - and three -quarter perimeters and the patella tendon perim eter. The abduction -adduction angle was calculated by finding the principal axis of the mesh below the patella tendon. Volume and area reductions were calculated by comparing limb and socket shapes. Finally, the distributions of rectification sizes were ex tracted using the K -Means Clustering method. These measures were inspected for the whole training population and for the PTB and TSB socket groups. A Kolmogorov -Smirnov test was used to assess whether data were normally distributed. Differences between measures for the PTB and TSB groups were assessed for statistical significance using an unpaired Student’s t-test (for parametric measures) and a Mann -Whitney U test (for non -parametric measures). Two -tailed tests were used for limb shape measures, where hypo theses assumed the populations were equal. One -tailed tests were used for rectification measures, where hypotheses assumed the PTB designs would have larger rectifications. Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice Results Statistical models were built using PCA for the limb shape (SLM), socke t design (SDM) and combined limb shape and socket design (SLDM). Plots of cumulative variance across each model’s modes (Fig.4a -c) show that 95% of the population variation was captured by 3, 19 and 4 modes for the limb shape, socket design and combined mo dels, respectively. When randomly selected training datasets were reconstructed using different training population sizes (Fig.4d -f), leave -one-out (LOO) testing revealed that around 40 training limb and/or socket shapes are required for shape reconstructi ons from the SLM and SLDM models to have less than 1.0 mm mean error. The same accuracy was achieved for the SDM using only 10 training socket shapes. The SLM was able to discriminate between the main independent modes of limb shape variation (Fig.5). Variation presented as the limb’s overall size (mode 1 containing 85% of population variation), with larger limb circumference and width corresponding with longer length; and the limb’s soft tissue bulk (mode 2, 8.3% of variation). Mode 3 (2.5% of variation) d escribed abduction -adduction angle at the knee. Mode 4 (1.1% of variation) represented calf muscle bulk, most apparent in the sagittal view, and mode 5 (0.6% of variation) contained the limb’s bulbous -conical profiles in the sagittal and coronal planes. Mo de 2 demonstrates that larger circumference limbs were more likely to be bulbous shaped and smaller circumference limbs a more cylindrical or conical, and Modes 4 and 5 indicate how the profile can also vary independent of limb size or soft tissue bulk. (a) (b) (c) (d) (e) (f) Figure 4. Cumulative mode variance graphs (a -c) and leave -one-out (LOO) error graphs (d -e) for statistical limb shape model (SLM, a&d), statistical socket design model (SDM, b&e) and statistical limb shape and socket design model (SLDM, c&f) cases. Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice Figur e 5. First five mode variations for the Statistical Shape Model (SSM), showing ±2 standard deviation shapes either side of th e mean. Shape variation observations (Obs) are labelled. The SDM was able to discriminate between the main independent trends in prosthetic socket design variation (Fig.6). The first mode (containing 35% of population variation) showed an apparent trend between the commonly grouped rectifications of the PTB and TSB socket design philosophies. At one extreme of Mode 1, PTB -dominant d esign features were observed with notable rectifications at the patella tendon bar, lateral and medial areas either side of the anterior tibial crest (all visible on the anterior view), and relief over the fibula head (visible on the lateral view). Posteri orly, nearly matching limb -socket fit was observed. At the other extreme of Mode 1, TSB -dominant design features were observed. The socket was a similar shape to the limb, with slight press -fit/interference around the limb periphery and few local rectifica tions except at the patella tendon bar, and substantial distal tip off -loading. The next three modes appeared to show these local socket rectifications in combination with various extents of the PTB -TSB grouped features. Mode 2 (25% of variation) presented variation between PTB and TSB designs but with the distal tip off -loading aligned with the PTB design. Mode 3 (8.5% of variation) showed the fibula head off -loading feature presenting more strongly in the TSB design, than in the PTB with which it is norma lly associated. Mode 4 (5.1% of variation) showed variation in the patella tendon bar rectifications. Finally, mode 5 (3.9% of variation) showed little variation in the pattern or magnitudes of rectification, but showed their locations varying in internal -external rotation. In summary, PCA performed upon socket rectification data did not generate an SDM which discriminated between individual rectifications, instead identifying variance in combined rectification groups. The SLDM (Fig.7) showed very similar l imb shapes and variance to the pure statistical limb shape model (Fig.5), which dominated the modes. However, this model revealed trends in socket design which correspond with the shape variation. A more PTB -like design was observed for larger, longer limb shapes (mode 1), for more bulbous limb shapes (modes 2 and 5), and for limbs with less defined calf tissue (mode 4). More TSB - like sockets corresponded with limbs that were smaller (mode 1), more slender or cylindrical (modes 2 and 5) and with more define d calf tissue (mode 4). Mode 3 contained abduction -adduction angle variation at the knee, and showed little socket design variation except a slightly more marked fibula head buildup in abducted limbs. Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice Figure 6. First five mode variations for the Statisti cal Design Model (SDM), showing the 2.5th and 97.5th percentile shapes. Rectification map units: mm. Design variation Observations are labelled. Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice Figure 7. First five mode variations for the Statistical Limb Shape and Socket Design Model (SLDM), showing m ean ±2 standard deviation shapes. Rectification map units: mm. Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice The main shape and design correspondences identified in the PCA statistical models are summarised in Table 1. The training population was observed to be normally -distributed in the generated limb shape and combined limb shape and socket design models, but the statistical socket design model was not normally distributed (Fig.A1). Table 1. Descriptions and proportional variance in shape and/or design described by the first five modes in each model. Mode No. Mode Variance and Description for each Statistical Model: Limb Shape (SLM) Socket Design (SDM) Limb Shape and Socket Design (SSDM) 1 (85%) Size and Length: Long/Large to Small/Short (35%) PTB to TSB with Distal Tip space (83%) Large & PTB to Small & TSB 2 (8.3%) Bulky to Slender soft tissue (25%) PTB with Distal Tip space to TSB (8.2%) Bulky & PTB to Slender & TSB 3 (2.5%) Angle of knee, Abducted to Adducted (8.5%) PTB to TSB with Fibula Head rectns. (2.5%) Abducted to Adducted knee 4 (1.1%) Sagittal profile, conical to bulbous (5.1%) PTB to TSB with patella tendon and anterior tibia rectns. (1.1%) Profile: conical PTB to bulbous TSB 5 (0.6%) Coronal profile, conical to bulbous (3.9%) Internal -External Rotation of Tibia (0.7%) Profile: bulbous PTB to conical TSB The K -Means Cluster analysis permitted statistical analysis of the training sockets’ individual rectification sizes (Fig.8). Against a human observer, the method classified rectifications with 97.3% accuracy overall, including 100% for PT and DE (Table 2). After correcting the few incorrectly classified rectifications, the method identified that all sockets had a rectification at the patella tendon. At least one paratibial rectification was identified all sockets except one from each group. Fibula head rect ifications featured in 49/55 PTB sockets but only 6/12 TSB sockets. The limb shape and socket design distributions were extracted (Table 3). No statistically significant limb shape measures were observed between the individuals who received PTB and TSB soc kets (p>0.05). Inspecting the socket volume and cross -sectional area reduction measures, TSB sockets were smaller compared to the limb than PTB sockets, although this did not reach statistical significance (0.23≤p≤0.36). The local PT, MP and LP rectificati ons were normally distributed (Fig.8a,c&d). No difference was found between the PT rectification size for each group (p=0.40). The paratibial rectifications were larger for the PTB designs, but this was marginally insignificant for the lateral side (p=0.05 1). The fibula head and distal end rectifications (Fig.8b&e) were skewed owing to many sockets with small or no rectification at these sites. Larger DE rectifications were seen for the TSB sockets, a compensation for their greater press -fit as the near -incompressible posterior soft tissues must be accommodated elsewhere. The difference between PTB and TSB groups was not significant (p=0.21). PTB sockets had significantly more pronounced FH rectifications than TSB sockets (p=0.03). Table 2. Prevalence of ea ch rectification, and accuracy of classification by K -Means Clustering. Rectification PT FH MP LP DE Prevalence, % 100 82 94 97 91 Classification, % 100 93 99 96 100 Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice (a) (b) (c) (d) (e) (f) Figure 8. Histograms of local rectification sizes across the training population for (a) patella tendon, (b) fibula head, (c) medial and (d) lateral paratibial, and (e) distal end design features as mapped on the (f) 3D socket shape. -ve denotes buildup, +ve denotes carve. Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice Table 3. Training dataset shape and socket design measures. Measure Whole Group (n=67) PTB Group (n=55) TSB Group (n=12) Residual Limb Anatomy: normally distributed: mean (s.d.) Limb length, mm 156 (29) 157 (29) 153 (31) Perimeter at patella tendon, mm 383 (40) 383 (42) 385 (34) Perimeter at ½ limb length, mm 366 (51) 358 (55) 355 (30) Perimeter at ¾ limb length, mm 327 (48) 329 (52) 315 (24) Profile ratio at ½ limb length1 0.95 (0.06) 0.96 (0.06) 0.92 (0.05) Profile ratio at ¾ limb length1 0.85 (0.07) 0.86 (0.07) 0.82 (0.04) Abduction / adduction angle, ° 0.7 (1.9) 0.7 (2.0) 0.5 (1.6) Gross Socket Sizing: normally distributed: mean (s.d.) Overall volume reduction, % -1.9 (4.3) -1.6 (4.4) -3.1 (3.7) Area reduction at patella tendon, % -4.1 (5.7) -3.8 (5.6) -5.6 (5.8) Area reduction at ½ limb length, % -6.0 (4.5) -5.7 (4.2) -7.7 (5.4) Area reduction at ¾ limb length, % -1.9 (5.8) -1.6 (5.8) -3.7 (5.5) Local Socket Rectifications: non -normally distributed: median (10th - 90th percentile range) Patella tendon rect. depth, mm 6.7 (4.2 – 9.0) 6.7 (4.2 – 9.1) 6.6 (3.8 –8.6) Fibula head rect. height, mm -1.0 (-4.2 – 0.4) -1.6 (-4.4 – 0.4) 0.0 (-3.0 – 0.4)* Medial paratibial rect. depth, mm 4.3 (0.9 – 6.9) 4.5 (1.2 – 6.9) 3.8 (0.0 – 7.2) Lateral paratibial rect. depth, mm 4.9 (1.5 – 7.8) 4.9 (2.8 – 7.9) 3.5 (-0.2 – 8.7) Distal end rect. height, mm -4.2 (-15.4 – 0.0) -4.1 (-14.4 – 0.0) -5.2 (-21.0 – -0.6) 1 Profile ratio of 1 is cylindrical, below 1 is conical, above 1 is bulbous. * indicates a statistically significant difference between PTB and TSB groups at the p<0.05 level. Discussion This study applied supervised machine learning methods to evaluate trends in the shape of residual limbs and corresp onding expert -designed prosthetic sockets. It investigated how population -based models might be built, and whether separate shape and design models might provide higher resolution for machine learning than a combined shape and design model. Global limb sha pe trends were captured and separated clearly using principal component analysis of surface shape. The same method distinguished the main overall trends in prosthetic socket design (i.e. PTB and TSB), but it was less successful in separating the variations in discrete local rectifications. For this purpose a K -Means Clustering model was trained to identify specific rectifications so that they could be compared quantitatively. Correspondences in anatomy and socket design variation were inspected to identify whether there were trends in the socket design approach for particular residual limb shapes in the training dataset. Observations: The Statistical Limb Model (Fig.5) showed detailed distinction between different shape profiles, with different modes capturi ng independent variations in gross tissue bulk (Mode 2) and the conical -cylindrical -bulbous profile in sagittal (Mode 4) and coronal (Mode 5) planes. The modes showing coronal plane bulbousness varying to a cylindrical profile (Mode 2, and particularly Mod e 5 which shows medial and lateral ‘ears’) might indicate short -term swelling and oedema which subsides in the months following surgery, whereas the bulbous to conical shape variance seen in the sagittal plane (Mode 4) might be associated more with activit y level and atrophic effects. These theories were tested in a secondary analysis of correlation between the SLM mode scores and time -since -amputation (Table A1). No correlation was seen for Modes 1, 3 and 4 (r<0.1, p>0.4) but weak correlations were observe d for the bulbousness -shape Modes 2 and 5 (r=0.23 and 0.28, respectively), which reached significance for Mode 5 (p=0.065 and 0.026, respectively). The socket design model’s modes did not clearly distinguish between separate local rectifications (Fig.6). The first mode clearly showed the established trends in PTB and TSB socket designs, in fine detail. For example, a difference can be seen in the straight patella tendon ‘bar’ rectification in the PTB design, compared to the TSB’s more curved, anatomy -follow ing modification at this site (compare to Fig.2). [6] However, subsequent SDM modes contained variation in local rectifications combined with thes e overall design variation trends, so this method did not allow direct assessment of individual rectification sizes and shapes. The SLDM however showed some general trends between limb shape and socket design which are Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice consistent with clinical practice. Cl inical, functional and user preference for TSB and PTB sockets is complex, and highly influenced by the liners and accessories they are worn with, [37], [38] though there is some evidence to support the choice of socket when considering residuum shape and tissue composition. TSB sockets are reported to be preferred for “stumps w ithout oedema and pain”, which are more common in early rehabilitation. [39] PTB sockets are used for earlier rehabilitation where the strategic proximal loading and distal offloading protects the vulnerable soft tissue reconstruction. [40] TSB sockets are p referred for individuals with mature residual limbs of stable volume, without excessive soft tissue, and which are not excessively long, [41] although they may be more difficult to fit to highly conical shaped limbs. [6] Bulbous limbs are understood to require PTB sockets, as it would be difficult to don a TSB socket over a bulbous distal shape and achieve the desired uniform load transfer. These clinical use principles are consistent with the correlations observed in thi s study’s SLDM, where socket designs had more PTB -like features in longer, larger, more bulbous limb shapes (Fig.7). More detailed analysis of personalised local rectifications was possible using the K -Means Clustering approach. Inspection of rectification s across the training population revealed that many of the same rectification features were used for both PTB and TSB socket designs. No differences in patellar tendon or distal tip rectifications were observed, though PTB sockets had larger paratibial and fibular head rectifications. TSB sockets were more tightly fitted to the limb than PTB sockets ( -3.1% vs. -1.6% by volume, on average). Only the FH rectification differences reached statistical significance, and the clinical significance of these fine variations in socket design are unknown. However, it is noteworthy that this method showed how expert prosthetists produce sockets across a continuum of design, instead of in discrete groups as the PTB and TSB approaches were originally presented. Prosthetic socket design may have evolved to employ the most biomechanically useful features of PTB and TSB approaches, tailored to individual patients. The present study shows how design is tailored to general limb shape trends (Fig.7), and further work is required to understand how detailed design is tailored to individuals. Limitations Statistical shape models are, at best, as limited as the data used to create them. It is risky to extrapolate their use outside the training population. This model will not necessar ily describe other populations, from different ecogeographic groupings or ethnicities, with their respective effects on physical characteristics, form of injury or disease, and surgical approach. For example, amputations may be performed at different heigh ts and with different soft tissue reconstructions depending on the reason for amputation (e.g. landmine trauma vs. road accident trauma vs. vascular disease), and there will be between -group differences in bony anatomy and soft tissue composition. Furtherm ore the socket population was biased towards PTB designs, with only 12 TSB sockets in the training dataset. The present method would be strengthened with more training data, but the training population was deemed acceptable for the present study as it was randomly sampled, and the TSB concept relatively closely matches the limb shape, so it might be described adequately with fewer models than the more variable PTB concept. Ultimately the socket design model was verified to within 1mm with only 10 socket sha pes. A further study limitation in scope is retrospective assessment of limb shape and socket design only, without a direct consideration of the residuum’s bony anatomy, soft tissue wounds or underlying pathology which might influence socket design, such as bon e spurs, heterotopic ossification, neuromata, bursae, adhered scars. In CAD/CAM clinical practice these are identified in limb assessment prior to socket design but not necessarily tracked in the CAD record. There have been proposals for how bony anatomy m ight be predicted from limb surface topology, using surface curvature [42] or an ANN [43]. However, the soft tissue pathological phenomena mentioned above would probabl y not be identifiable, so the use of any such data to inform new socket design would rely on template adaptation to the individual by a prosthetist, part of their value -added work. Implications and use As described earlier, the authors argue that it is ina ppropriate to try to fully automate the prosthetic socket design process. Instead this project builds upon proposals made early in CAD/CAM prosthetics [25], [27] , to learn from past experience for smart templating. With quantitative descriptions of the key trends in residual limb shape, a person’s limb can be compared to a population dataset, and simila r prior socket designs could be looked up. Supervised ML will allow trends in socket design to be scored by appropriate clinical outcome measures of comfort or function, providing templates which can be integrated in current CAD/CAM workflows. Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice This process requires expert human input throughout, from development to clinical use, to provide the key value of patient -centred design (Fig.1). According to the Pareto 80:20 principle [44] this expert -led proposal could protect the prosthe tists’ time to provide their skill where it is most valuable, in adapting the template to their patient. As such, the presented methods could support evidence -based approaches to save time and iteration towards an acceptable socket, and sharing best practi ce with colleagues and trainees. Ahead of such templates, this study provides quantitative measures of clinically -used socket rectifications and press - fit (Table 3), reveals a design continuum between more PTB -like and more TSB -like sockets, and demonstrat es how prosthetists select these features for different limb shapes (Fig.7). Beyond direct clinical application, characterisation of residual limb size and shape variability is useful to ensure that biomechanical analysis models are representative of a br oad population of prosthesis users. Without access to such data, Silver -Thorn [45], [46] developed a generic FEA model o f the transtibial amputated limb that was resized for the individual to estimate interface stresses with various socket designs, but used standard geometric shapes rather than accurate geometries, and did not account for limb shape variations. The same sha pe PCA method presented here has been used with finite element mesh morphing to produce an FE limb model scaled from an MRI scan onto a population of surface scans, enabling far more general FE predictions than a single model allows [32]. Where many FE studies have used single - or highly simplified, volume -scaled socket designs, [16] the presented shape analysis method and quantitative rectification data (Table 3) would enable modellers to work with more clinically representative sockets. Conclusions : This study provides methods for population -based socket design analysis which will support developments in CAD/CAM clinical practice and accuracy of biomechanics research. These methods may help to reduce clinic time and iterations required to fit a comfortable socket. Bearing in mind the mentioned limitations, we advise care in interpreting and using the present study ’s findings. These design trends are observations from a single group of patients and clinicians, and they do not imply any causal link between design and outcome. As such the present study’s results do not represent recommendations for clinical practice a nd will not apply to all patients and clinical situations. The proposal of any socket design guideline or template should be validated in a blinded, controlled clinical study comparing from -template and from -scratch sockets. The authors reiterate our posit ion that prosthetic socket design should not be fully automated, but that the process may be improved using smart socket templates, fitted by a highly trained prosthetist. Acknowledgments: This research was funded by the Royal Academy of Engineering (RAEn g), grant numbers RF/130 and EF1819 \8\24 and the Engineering and Physical Sciences Research Council (EPSRC) / National Institute for Health Research (NIHR) Global Challenges Research Fund programme, grant number EP/R014213/1. Institutional Review Board Sta tement: The study was conducted according to the guidelines of the Declaration of Helsinki, and approved by the Institutional Ethics Committee of University of Southampton (protocol code ERGO 53279 on 11th November 2019. Patient consent was waived due to t he study’s retrospective, anonymised analysis of data collected under routine clinical practice, structured as a service development audit. This approach was supported by a committee chair from the UK National Research Ethics Service (NRES). We acknowledge kind support from Dr Peter Worsley, Dr Sonia Zakrzewski and Prof James Batchelor, and the University of Southampton’s Institute for Life Sciences. Raw data will be made openly available from the University of Southampton repository at https://doi.org/10.5258/SOTON/D1942 (to be activated upon peer reviewed publication ). Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice Appendix : Figure A1. Histograms of training dataset mode scores for the SLM, SDM and SLDM. Greatest deviation from normal distributions is observed for the statistical design model. Table A1: Correlations between statistical limb model mode scores and participant metadata: Correlations between SLM modes and participant metadata Mode 1 2 3 4 5 Gross Size: Large to Small Soft Tissue: Bulky to Slender Knee angle: Adducted to Abducted Sag. profile: conical to bulbous Cor. profile: conical to bulbous Time Since Amputation r 0.10 0.23 0.02 0.05 0.28 p 0.433 0.065 0.865 0.702 0.026* * denotes statistically significant correlations (p<0.05). Characterising Residual Limb Morphology and Prosthetic Socket Design based on Expert Clinician Practice