Fibre & Yarn Quality Prediction
HVI Analytics, Uster Evenness Modelling, and Spinning Parameter Optimisation
Why Quality Prediction Beats Quality Inspection
Inspection at the ring frame or winding stage catches defects after they have already consumed energy, labour, and time. Predictive models trained on High Volume Instrument (HVI) fibre data and inline Uster evenness readings push quality decisions upstream to the ginning floor and mixing room — where intervention costs pennies instead of rupees per kilogram. This chapter works through the full prediction pipeline: raw cotton grading, fibre property modelling, spinning parameter optimisation, and defect rate forecasting.
Open data/hvi-fibre-data.csv in the code panel. It contains HVI readings from three seasons of Shankar-6 and MCU-5 cotton procured through the Cotton Corporation of India (CCI) auctions in Rajkot and Akola — 2,400 bale records with UHML, UI, Mic, Str, Elo, SCI, Rd, and +b columns alongside gin source, moisture at receipt, and final yarn count.
HVI Parameter Relationships and SCI as a Composite Target
The Spinning Consistency Index (SCI) combines HVI outputs into a single predictor of yarn quality:
SCI = −414.67 + 2.9 × Str + 49.17 × Mic − 36.03 × Mic² + 1.0 × UHML + 3.0 × UI + 0.65 × Rd + 0.36 × +bSCI is a useful regression target, but it hides non-linear interactions that matter at count extremes. For Ne 80s combed yarn spun from MCU-5, short fibre content (SFC) — which HVI reports but SCI ignores — is the dominant predictor of end-breakage rate. Build separate models per count range rather than a single SCI regressor.
| HVI Parameter | Unit | MCU-5 Typical | Shankar-6 Typical | Effect on Yarn Tenacity |
|---|---|---|---|---|
| UHML (Upper Half Mean Length) | mm | 28.5–30.5 | 29.0–31.0 | +0.8 cN/tex per mm |
| UI (Uniformity Index) | % | 83–86 | 84–87 | Non-linear; drops sharply <82% |
| Mic (Micronaire) | — | 3.5–4.2 | 4.0–4.9 | Optimal 3.7–4.3; coarse > 5.0 adds neps |
| Str (Fibre Strength) | gf/tex | 28–32 | 26–30 | Linear, most direct tensile predictor |
| SFC (Short Fibre Content) | % | 8–14 | 10–16 | Each +1% SFC → +0.4 ends/1000 spindle-hrs |
| Rd (Reflectance) | % | 72–78 | 70–76 | Affects dyeability, not tenacity |
Building the Fibre-to-Yarn Quality Model
Feature Engineering
Raw HVI columns are not the best model inputs. Derived features that capture blend dynamics:
SFC_n = SFC / UHML captures the relative proportion of short fibre independent of length grade.Prompt: "I have HVI data for a 5-lot cotton blend. UHML values are [29.1, 28.6, 30.2, 29.8, 28.9] mm,
Mic values are [4.1, 3.9, 4.6, 4.0, 3.8], SFC values are [10.2, 12.1, 9.8, 11.4, 13.0]%.
The target yarn count is Ne 40s carded ring spun. Predict the expected CSP (Count Strength Product)
range and identify which lot is the weakest link in this blend. Recommend whether to reject
the high-SFC lot or adjust blend percentage."Model Architecture Choices
For structured tabular HVI data, gradient boosting outperforms deep networks on datasets of < 50,000 records:
| Model | RMSE on Ne 40s CSP | Training Data Needed | Inference Latency |
|---|---|---|---|
| XGBoost (HVI features only) | ±180 CSP | 500+ bales | < 1 ms |
| XGBoost + spinning params | ±110 CSP | 800+ bales | < 1 ms |
| LSTM over seasonal sequences | ±95 CSP | 3+ seasons | ~5 ms |
| Random Forest baseline | ±220 CSP | 300+ bales | < 1 ms |
The LSTM advantage arises from its ability to capture seasonal cotton quality drift — Shankar-6 from new-crop October lots performs differently from the same variety in March carry-forward lots. If you have < 3 seasons of data, XGBoost + spinning parameters is the practical choice.
Uster Evenness Prediction and Inline Feedback
The Uster Tester 6 reports CV% (mass variation), thin places (−50%), thick places (+50%), neps (+200%), and hairiness (H) every 400m. These are outcome metrics — the goal is to predict them from upstream process data before the yarn leaves the ring frame.
Open data/yarn-evenness-report.json for 90 days of Uster readings from a Coimbatore mill running Ne 30s and Ne 60s combed ring spun on Rieter G 38 ring frames. The JSON structure links each Uster record to its upstream card sliver CV%, draw frame CV%, and simplex CV% readings.
Control Chart Integration
Statistical Process Control (SPC) for Uster data uses CUSUM (cumulative sum) charts rather than Shewhart X̄-R charts because yarn evenness follows a non-normal distribution with fat tails:
import numpy as np
def cusum_uster(cv_series: list[float], target: float, k: float = 0.5, h: float = 5.0):
"""
CUSUM for Uster CV% series.
target: process mean CV% (e.g., 12.4 for Ne 30s combed)
k: allowance (slack), typically 0.5 sigma
h: decision interval, typically 4-5 sigma
"""
C_pos, C_neg = 0.0, 0.0
alerts = []
for i, cv in enumerate(cv_series):
C_pos = max(0, C_pos + (cv - target) - k)
C_neg = max(0, C_neg - (cv - target) - k)
if C_pos > h or C_neg > h:
alerts.append({"index": i, "cv": cv, "C_pos": C_pos, "C_neg": C_neg})
C_pos, C_neg = 0.0, 0.0
return alertsWhen the CUSUM fires, the alert should trigger an investigation queue item in the mill MES (Manufacturing Execution System), not just a dashboard notification — the time between alert and corrective action is the key KPI.
Spinning Parameter Optimisation
Ring Spinning: Key Controllable Variables
| Parameter | Effect | Typical Range | Optimisation Direction |
|---|---|---|---|
| Spindle speed (RPM) | Higher speed → more end-breakage, heat | 18,000–24,000 | Maximise within end-breakage budget |
| Traveller weight (mg) | Heavy → more twist drag, balloon control | 50–120 mg (Ne 40s) | Tune per count + fibre combo |
| Ring diameter (mm) | Larger → higher balloon tension | 38, 42, 45 mm | Fixed per frame; affects traveller choice |
| Draft ratio | Higher draft → thinner sliver input, more CV% | 28–38× (ring) | Lower draft preferred for weak fibre lots |
| Twist multiplier (TM) | Higher TM → stronger yarn, lower count | 3.8–4.6 (carded) | Bayesian optimise vs. strength target |
Bayesian Optimisation for TM + Spindle Speed
Instead of factorial DOE (which requires hundreds of trial lots), use Gaussian Process Bayesian optimisation to navigate the TM × spindle-speed surface with 15–20 trials:
Prompt: "I am optimising ring spinning parameters for a Ne 40s carded yarn from a blend of
Shankar-6 (60%) and MCU-5 (40%). Current results: TM 4.1, spindle 21,000 RPM, CSP 2,850,
end-breakage rate 8.2/1000 spindle-hours. My targets are CSP ≥ 3,000 and end-breakage ≤ 6.0.
I can vary TM from 3.9 to 4.4 and spindle speed from 19,000 to 22,500 RPM.
Propose the next 3 trial points using Bayesian optimisation logic, explaining the
exploration-exploitation trade-off for each."Rotor and Air-Jet Context
Rotor spinning (OE) at Ludhiana hosiery mills running Ne 10s–20s cotton-polyester blends has different optimisation levers: rotor diameter, rotor speed, opening roller speed, and navel type. Air-jet spinning (Murata VORTEX) for Ne 40s–60s viscose-cotton blends centres on nozzle pressure and delivery speed. The feature set for quality prediction differs but the GP-Bayesian framework applies identically.
Indian Cotton Grading and Market Linkage
India's cotton grading system under the Cotton Act 1986, administered by the Textile Commissioner, uses a two-digit code (e.g., J-34 for Shankar-6 premium, J-32 for standard). The CCI procurement price varies by grade — knowing that a lot's HVI profile maps to J-34 vs. J-32 has a ₹1,500–2,000/quintal price implication.
A classification model trained on HVI data from CAI (Cotton Association of India) grading reports can predict the CCI grade before sending samples to the official grader — giving the purchase team 48–72 hours of lead time for auction decisions. The Ahmedabad-based ATIRA (Ahmedabad Textile Industry's Research Association) maintains a reference HVI database for Gujarati cotton varieties that is available to member mills.
Key Takeaways
This is chapter 1 of AI for Textile & Apparel.
Get the full hands-on course — free during early access. Build the complete system. Your projects become your portfolio.
View course details