Note: This document is an English translation. The original version is in Japanese.
Overview
Tera-Calculation EIQAI is a Windows Forms application that utilizes ML.NET pre-trained models to perform AI predictions for EIQ Analysis (E = Entry/Destination, I = Item, Q = Quantity) within logistics centers.
Objectives
Using only two input parameters—the number of destinations and the number of items—the system simultaneously predicts 162 items required for EIQ analysis (Piece Quantity, Line Count, Destination Ranks E1-E5, Item Ranks I1-I5, and numerical breakdowns across 25 ranks for lines, pieces, cases, pallets, volume, and weight) and visualizes them as matrix and traditional calculation tables.
Operating Environment / Technical Stack
| Item | Content |
| Framework | .NET Framework 4.8 / Windows Forms (VB.NET) |
| AI/ML Library | Microsoft.ML (ML.NET 6.0 Preview) |
| Database | Microsoft Access (.accdb) — Automatically optimized via JRO.JetEngine at startup |
| Model Format | Pre-trained ITransformer (.zip) — 162 models loaded at once |
| Storage Path | TeraCalculationData\EIQAnalysisAI folder (Auto-detects drives A to F) |
| Excel Output | Compatible with EPPlusFree library |
Main Features
- AI Prediction Execution: Predicts 162 items individually using pre-trained models based on user input of destination and item counts.
- EIQ Matrix Table: Automatically generates a 5×5 matrix of GPLE Rank (E1-E5) × GPLI Rank (I1-I5). Units switchable between Frequency, Pieces, Cases, Pallets, Volume, and Weight.
- Traditional Calculation Table E: Aggregates indicators (shipping frequency, piece count, case conversion, etc.) by destination rank (GPLE_A1 to D).
- Traditional Calculation Table I: Aggregates identical indicators column-wise by item rank (GPLI_A1 to D).
- Result Export: Outputs results to a CSV file (
PredictionResults_yyyyMMdd_HHmmss.csv).
- Model Reloading: Rescans the model folder for .zip files to update to the latest models.
- Access DB Optimization: Automatically compacts the DB at startup if the file size exceeds the 100MB threshold.
Development Information
| Item | Content |
| Developer | Logistics Technology Institute |
| Copyright | Toshiyuki Teramoto |
Overall Flow
App Startup (Form Load)
▼
Initialization Process
MLContext / Load Models / Grid Setup
▼
User Input
Destinations & Items Count
▼
Click "Run Prediction"
▼
Prediction Execution()
Predict via all models → Display in Prediction Grid
▼
Click "Generate EIQ Matrix"
▼
Create Matrix Table
Create Trad. Calculation E
Create Trad. Calculation I
▼
Switch Display Unit Radio Buttons
Frequency/Pieces/Cases/etc. → Redraw Matrix
Detailed Process Descriptions
【1】 Form Load (TeraCalculationEIQAI_Load)
- Invokes
FileConfirmation().
- Initializes
MLContext(seed:=0).
- Verifies existence of the model storage folder.
Output Field Name List Initialization():
- Piece Quantity, Line Count, E1-E5, I1-I5
- Line Count 01-25, Piece Quantity 01-25, Case 01-25, Pallet 01-25, Volume 01-25, Weight 01-25
- Total of 162 fields
Load Trained Models(): Loads all .zip files in the folder as ITransformers.
AI Prediction EIQ Matrix Grid Initialization(): Sets header for 7 columns × 5 rows.
【2】 Prediction Execution (Run Prediction Bt_Click → Prediction Execution())
- Validates numerical inputs in Destination Tb and Item Tb.
- Creates
InputData (Destinations, Items).
- Executes
CreatePredictionEngine → Predict for all 162 trained models.
- Stores prediction results in a
Dictionary(Of String, Single).
Display Prediction Results(): Converts results to a DataTable and binds to the Prediction Grid.
【3】 EIQ Matrix Table Creation (AI Prediction EIQ Matrix())
- Caches results from the Prediction Grid into a dictionary (pred) with rounded integers.
- Determines unit prefix based on radio button selection.
- Fills the 25 cells (5×5 matrix) and calculates horizontal totals (row totals), vertical totals (column totals), and the grand total.
| GPLE Rank | GPLI_A1 | GPLI_A2 | GPLI_B | GPLI_C | GPLI_D | Row Total |
| GPLE_A1 | XX01 | XX02 | XX03 | XX04 | XX05 | Σ Row |
| GPLE_A2 | XX06 | XX07 | XX08 | XX09 | XX10 | Σ Row |
| GPLE_B | XX11 | XX12 | XX13 | XX14 | XX15 | Σ Row |
| GPLE_C | XX16 | XX17 | XX18 | XX19 | XX20 | Σ Row |
| GPLE_D | XX21 | XX22 | XX23 | XX24 | XX25 | Σ Row |
| Col Total | Σ Col | Σ Col | Σ Col | Σ Col | Σ Col | Grand Total |
※ XX = Unit prefix (Frequency / Pieces / Case / PL / Volume / Weight)
【4】 Traditional Calculation E (AI Prediction Trad. Calc E())
- Configures 9 columns in the
AI Prediction Trad. Calc Destination Grid.
- Aggregates indicators for each Destination Rank (GPLE E1-E5).
| Ship Date | Rank | Dest. Count | Freq. | Pieces | Cases | Pallets | Volume | Weight |
| Avg All | GPLE_A1 | E1 | Σ Lines 01-05 | Σ Pcs 01-05 | Σ Case 01-05 | Σ PL 01-05 | Σ Vol 01-05 | Σ Wgt 01-05 |
| Avg All | GPLE_A2 | E2 | Σ Lines 06-10 | Σ Pcs 06-10 | Σ Case 06-10 | Σ PL 06-10 | Σ Vol 06-10 | Σ Wgt 06-10 |
| Avg All | GPLE_B | E3 | Σ Lines 11-15 | Σ Pcs 11-15 | Σ Case 11-15 | Σ PL 11-15 | Σ Vol 11-15 | Σ Wgt 11-15 |
| Avg All | GPLE_C | E4 | Σ Lines 16-20 | Σ Pcs 16-20 | Σ Case 16-20 | Σ PL 16-20 | Σ Vol 16-20 | Σ Wgt 16-20 |
| Avg All | GPLE_D | E5 | Σ Lines 21-25 | Σ Pcs 21-25 | Σ Case 21-25 | Σ PL 21-25 | Σ Vol 21-25 | Σ Wgt 21-25 |
| Total | Σ E | Σ All | Σ All | Σ All | Σ All | Σ All | Σ All |
【5】 Traditional Calculation I (AI Prediction Trad. Calc I())
- Configures 9 columns in the
AI Prediction Trad. Calc Item Grid.
- Aggregates indicators column-wise for each Item Rank (GPLI I1-I5).
| Ship Date | Rank | Item Count | Freq. | Pieces | Cases | Pallets | Volume | Weight |
| Avg All | GPLI_A1 | I1 | Σ Lines col1 | Σ Pcs col1 | Σ Case col1 | Σ PL col1 | Σ Vol col1 | Σ Wgt col1 |
| Avg All | GPLI_A2 | I2 | Σ Lines col2 | Σ Pcs col2 | Σ Case col2 | Σ PL col2 | Σ Vol col2 | Σ Wgt col2 |
| Avg All | GPLI_B | I3 | Σ Lines col3 | Σ Pcs col3 | Σ Case col3 | Σ PL col3 | Σ Vol col3 | Σ Wgt col3 |
| Avg All | GPLI_C | I4 | Σ Lines col4 | Σ Pcs col4 | Σ Case col4 | Σ PL col4 | Σ Vol col4 | Σ Wgt col4 |
| Avg All | GPLI_D | I5 | Σ Lines col5 | Σ Pcs col5 | Σ Case col5 | Σ PL col5 | Σ Vol col5 | Σ Wgt col5 |
| Col Total | Σ I | Σ All | Σ All | Σ All | Σ All | Σ All | Σ All |
Column Total Logic: GPLI_A1 = XX01+XX06+XX11+XX16+XX21, GPLI_A2 = XX02+XX07+XX12+XX17+XX22, …
【6】 Display Unit Switching (Extraction_DisplayUnit_CheckedChanged)
- Operates only when
matrixActive = True.
- Re-executes
AI Prediction EIQ Matrix() to redraw the grid with the selected unit.
【7】 Results Export (Export Results Bt_Click)
- Outputs grid data to
PredictionResults_yyyyMMdd_HHmmss.csv.
- Adds input conditions (Destinations, Items) as header comments.
【8】 Trained Model Reloading (Load Trained Models Bt_Click)
- Rescans folder for .zip files and reloads them to update the memory.