Datasets:

smilegeng commited on
Commit
60e909f
·
verified ·
1 Parent(s): 74d97d1

chore: translate subset README to English and add format:tsfile tag

Browse files
Files changed (1) hide show
  1. hospital_admissions/README.md +62 -62
hospital_admissions/README.md CHANGED
@@ -1,62 +1,62 @@
1
- ---
2
- license: other
3
- task_categories:
4
- - time-series-forecasting
5
- tags:
6
- - time-series
7
- - tsfile
8
- pretty_name: hospital_admissions (TsFile format)
9
- ---
10
-
11
- # hospital_admissions — TsFile 格式
12
-
13
- 本目录是 [`autogluon/fev_datasets`](https://huggingface.co/datasets/autogluon/fev_datasets) 中 **hospital_admissions** 子集转换为 [Apache TsFile](https://tsfile.apache.org/) 格式的版本。
14
-
15
- ## 来源与引用
16
-
17
- - **原始来源**:https://www.kaggle.com/datasets/datasetengineer/riyadh-hospital-admissions-dataset-20202024
18
- - **论文/引用**:[[13]](https://doi.org/10.34740/kaggle/dsv/9992619)
19
- - **统一格式合集**:[autogluon/fev_datasets](https://huggingface.co/datasets/autogluon/fev_datasets)
20
-
21
- > 本数据由外部来源转换为统一格式后再转为 TsFile。许可与引用以**原始来源**为准,我们不对原始数据主张任何权利。除非另有说明,数据仅供研究用途。
22
-
23
- ## 数据统计
24
-
25
- | 频率 | 序列数 | 中位长度 | 观测点数 | 动态列 | 静态列 | 文件 |
26
- |---|---|---|---|---|---|---|
27
- | 1D | 8 | 1,731 | 13,846 | 1 | 0 | `1D/1D.tsfile` |
28
- | 1W | 8 | 246 | 1,968 | 1 | 0 | `1W/1W.tsfile` |
29
-
30
- ## TsFile 存储模型
31
-
32
- - 每条原始序列(`id`)→ 一个 **device**(TAG 维度)。
33
- - 随时间变化的 target / 动态协变量 → **measurement**(FIELD)。
34
- - `timestamp` → `Time`(INT64 毫秒)。
35
- - 表名:hospital_admissions_1D, hospital_admissions_1W。
36
-
37
- ### 列含义
38
-
39
- | 列 | 角色 | TsFile 类型 |
40
- |---|---|---|
41
- | `Time` | Time(时间列) | INT64 |
42
- | `id` | TAG(device 维度) | STRING |
43
- | `target` | FIELD(measurement) | FLOAT |
44
-
45
- > 注:有 16 个原始 id 含非法标识符字符,已规范化为合法 device 名(如 Dammam Central Hospital→Dammam_Central_Hospital, Dammam General Hospital→Dammam_General_Hospital, Jeddah National Hospital→Jeddah_National_Hospital)。
46
-
47
- ## 转换说明
48
-
49
- - 每行原始数据是一整条序列 `(id, timestamp[], 各 target[])`,纵向打平为长表后写入 TsFile。
50
- - 数值类型按源列自适应:float32→FLOAT、float64→DOUBLE、整数→INT64、bool→BOOLEAN。
51
- - 时间精度:毫秒(INT64)。
52
- - 大表会被工具自动分片为 `<名>_1.tsfile`、`<名>_2.tsfile` …,同属一个逻辑表。
53
-
54
- ## 读取示例
55
-
56
- ```python
57
- from tsfile import TsFileReader
58
-
59
- reader = TsFileReader("1D/1D.tsfile")
60
- schemas = reader.get_all_table_schemas()
61
- # 表名:hospital_admissions_1D;列见下方"列含义"。
62
- ```
 
1
+ ---
2
+ license: other
3
+ task_categories:
4
+ - time-series-forecasting
5
+ tags:
6
+ - time-series
7
+ - tsfile
8
+ - format:tsfile
9
+ pretty_name: hospital_admissions (TsFile format)
10
+ ---
11
+
12
+
13
+ # hospital_admissions (TsFile format)
14
+
15
+ ## Source and Citation
16
+
17
+ - **Original source**: https://www.kaggle.com/datasets/datasetengineer/riyadh-hospital-admissions-dataset-20202024
18
+ - **Paper / citation**: [[13]](https://doi.org/10.34740/kaggle/dsv/9992619)
19
+ - **Unified source collection**: [autogluon/fev_datasets](https://huggingface.co/datasets/autogluon/fev_datasets)
20
+
21
+ > This dataset was converted from external source data into a unified forecasting format and then into TsFile. Licensing and citation requirements follow the original source. We do not claim ownership of the original data. Unless otherwise stated, the data is intended for research use.
22
+
23
+ ## Dataset Statistics
24
+
25
+ | Frequency | Number of series | Median length | Observations | Dynamic columns | Static columns | Files |
26
+ |---|---|---|---|---|---|---|
27
+ | 1D | 8 | 1,731 | 13,846 | 1 | 0 | `1D/1D.tsfile` |
28
+ | 1W | 8 | 246 | 1,968 | 1 | 0 | `1W/1W.tsfile` |
29
+
30
+ ## TsFile Storage Model
31
+
32
+ - Each original series (`id`) is stored as one TsFile **device** (TAG dimension).
33
+ - Time-varying targets and dynamic covariates are stored as **measurements** (FIELDs).
34
+ - `timestamp` is mapped to `Time` as INT64 milliseconds.
35
+ - Table names: hospital_admissions_1D, hospital_admissions_1W.
36
+
37
+ ### Column Schema
38
+
39
+ | Column | Role | TsFile type |
40
+ |---|---|---|
41
+ | `Time` | Time column | INT64 |
42
+ | `id` | TAG (device dimension) | STRING |
43
+ | `target` | FIELD (measurement) | FLOAT |
44
+
45
+ > Note: 16 original `id` values contained invalid identifier characters and were normalized to valid device names, for example Dammam Central Hospital→Dammam_Central_Hospital, Dammam General Hospital→Dammam_General_Hospital, Jeddah National Hospital→Jeddah_National_Hospital.
46
+
47
+ ## Conversion Notes
48
+
49
+ - Each original row stores one complete series `(id, timestamp[], target and dynamic arrays)`. The converter flattens these nested rows into a long table before writing TsFile.
50
+ - Numeric types are inferred from the source columns, for example float32 to FLOAT, float64 to DOUBLE, integers to INT64, and bool to BOOLEAN.
51
+ - Time precision: milliseconds (INT64).
52
+ - Large tables may be automatically sharded as `<name>_1.tsfile`, `<name>_2.tsfile`, and so on. These shards belong to the same logical table.
53
+
54
+ ## Reading Example
55
+
56
+ ```python
57
+ from tsfile import TsFileReader
58
+
59
+ reader = TsFileReader("1D/1D.tsfile")
60
+ schemas = reader.get_all_table_schemas()
61
+ # Table name: hospital_admissions_1D; see \"Column Schema\" below.
62
+ ```