feat: 增加干扰小区方位角
This commit is contained in:
@@ -16,17 +16,17 @@ output/2026073110001100/
|
||||
└── manifest.json
|
||||
```
|
||||
|
||||
For every run, the script also reads the latest filename-dated XLSX from each configured CellData directory. It builds CellData CGI as `460-00-{eNB/gNB}-{CI}` and adds coordinates to matching interference rows. Unmatched rows keep empty coordinates.
|
||||
For every run, the script also reads the latest filename-dated XLSX from each configured CellData directory. It builds CellData CGI as `460-00-{eNB/gNB}-{CI}` and adds coordinates plus direction angle to matching interference rows. Unmatched rows keep empty coordinates and use `0` for azimuth.
|
||||
|
||||
The summary columns are:
|
||||
|
||||
```text
|
||||
hour_start,hour_end,cgi,cell_name,interference_dbm,longitude,latitude
|
||||
hour_start,hour_end,cgi,cell_name,interference_dbm,longitude,latitude,azimuth
|
||||
```
|
||||
|
||||
The script never modifies or deletes source storage files. By default it writes the complete selected hour through the Metrix Database API and keeps only that hour in the target table.
|
||||
|
||||
The database table contains one time column, `metric_time DATETIME`, which is the source KPI start time, plus nullable `longitude` and `latitude` columns. A same-hour rerun replaces that whole batch. After a successful insert, rows for every other hour are deleted in the same transaction. The script refuses to replace a newer database hour with an older source hour.
|
||||
The database table contains one time column, `metric_time DATETIME`, which is the source KPI start time, nullable `longitude` and `latitude` columns, and `azimuth DECIMAL(6,2) NOT NULL DEFAULT 0`. A same-hour rerun replaces that whole batch. After a successful insert, rows for every other hour are deleted in the same transaction. The script refuses to replace a newer database hour with an older source hour.
|
||||
|
||||
CGI is generated with fixed rules:
|
||||
|
||||
@@ -35,7 +35,7 @@ CGI is generated with fixed rules:
|
||||
|
||||
The Metrix API address, API Token, and database connection ID are constants in `runtime_config.py`; they are not project environment variables. Copy `runtime_config.example.py` to `runtime_config.py` and fill in the actual Token and the `conn_id` of `ShareMySQL`. The fixed database is `interference_etl`, the fixed table is `interference_hourly_summary`, and the script creates both automatically when they do not exist.
|
||||
|
||||
The five CellData directories are fixed in `CELL_DATA_DIRECTORIES`. In each directory, only XLSX files ending with a valid `YYYYMMDD.xlsx` date are considered, and the latest date is selected.
|
||||
The five CellData directories are fixed in `CELL_DATA_DIRECTORIES`. In each directory, only XLSX files ending with a valid `YYYYMMDD.xlsx` date are considered, and the latest date is selected. CellData column `方向角` maps to summary/database column `azimuth`; an empty source value becomes `0`.
|
||||
|
||||
## Local development
|
||||
|
||||
|
||||
Reference in New Issue
Block a user