five

SidneyBissoli/sipni-microdados

收藏
Hugging Face2026-03-01 更新2026-03-29 收录
下载链接:
https://hf-mirror.com/datasets/SidneyBissoli/sipni-microdados
下载链接
链接失效反馈
官方服务:
资源简介:
--- language: - pt license: cc-by-4.0 tags: - health - brazil - public-health - parquet - datasus - sipni - vaccination - immunization pretty_name: "SI-PNI — Routine Vaccination Microdata (Brazil)" size_categories: - 100M<n<1B task_categories: - tabular-classification source_datasets: - original --- # SI-PNI — Routine Vaccination Microdata (Brazil, 2020–present) Individual-level vaccination records from Brazil's National Immunization Program (SI-PNI), redistributed as partitioned Apache Parquet for efficient analytical access. Each row represents one administered dose. **Part of the [healthbr-data](https://huggingface.co/SidneyBissoli) project** — open redistribution of Brazilian public health data. ## Summary | Item | Detail | |------|--------| | **Official source** | OpenDATASUS / Ministry of Health | | **Temporal coverage** | January 2020 – present (monthly updates) | | **Geographic coverage** | All 5,570 Brazilian municipalities | | **Granularity** | Individual record (one row per administered dose) | | **Volume** | 736M+ records | | **Format** | Apache Parquet, partitioned by `ano/mes/uf` | | **Data types** | All fields stored as `string` (preserves leading zeros) | | **Update frequency** | Monthly | | **License** | CC-BY 4.0 | ## Resumo em português **SI-PNI — Microdados de Vacinação de Rotina (Brasil, 2020–presente)** Microdados individuais de vacinação de rotina do Sistema de Informação do Programa Nacional de Imunizações (SI-PNI), redistribuídos em formato Apache Parquet particionado para acesso analítico eficiente. Cada linha representa uma dose aplicada. | Item | Detalhe | |------|---------| | **Fonte oficial** | OpenDATASUS / Ministério da Saúde | | **Cobertura temporal** | Janeiro/2020 – presente (atualização mensal) | | **Cobertura geográfica** | Todos os 5.570 municípios brasileiros | | **Granularidade** | Registro individual (uma linha por dose aplicada) | | **Volume** | 736M+ registros | | **Formato** | Apache Parquet, particionado por `ano/mes/uf` | | **Atualização** | Mensal | > Para documentação completa em português, consulte o > [repositório do projeto](https://github.com/SidneyBissoli/healthbr-data). ## Data access Data is hosted on Cloudflare R2 and accessed via S3-compatible API. The credentials below are **read-only** and intended for public use. ### R (Arrow) ```r library(arrow) library(dplyr) Sys.setenv( AWS_ENDPOINT_URL = "https://5c499208eebced4e34bd98ffa204f2fb.r2.cloudflarestorage.com", AWS_ACCESS_KEY_ID = "28c72d4b3e1140fa468e367ae472b522", AWS_SECRET_ACCESS_KEY = "2937b2106736e2ba64e24e92f2be4e6c312bba3355586e41ce634b14c1482951", AWS_DEFAULT_REGION = "auto" ) ds <- open_dataset("s3://healthbr-data/sipni/microdados/", format = "parquet") # Example: vaccines administered in Acre, January 2024 ds |> filter(ano == "2024", mes == "01", uf == "AC") |> count(ds_vacina) |> collect() ``` ### Python (PyArrow) ```python import pyarrow.dataset as pds import pyarrow.fs as fs s3 = fs.S3FileSystem( endpoint_override="https://5c499208eebced4e34bd98ffa204f2fb.r2.cloudflarestorage.com", access_key="28c72d4b3e1140fa468e367ae472b522", secret_key="2937b2106736e2ba64e24e92f2be4e6c312bba3355586e41ce634b14c1482951", region="auto" ) dataset = pds.dataset( "healthbr-data/sipni/microdados/", filesystem=s3, format="parquet", partitioning="hive" ) table = dataset.to_table( filter=(pds.field("ano") == "2024") & (pds.field("uf") == "AC") ) print(table.to_pandas().head()) ``` > **Note:** These credentials are **read-only** and safe to use in scripts. > The bucket does not allow anonymous S3 access — credentials are required. ## File structure ``` s3://healthbr-data/sipni/microdados/ README.md ano=2020/ mes=01/ uf=AC/ part-0.parquet uf=AL/ part-0.parquet ... mes=02/ ... ano=2021/ ... ``` Each Parquet file contains records for a specific month and state. Hive-style partitioning (`key=value`) enables automatic partition pruning in Arrow and DuckDB — filtered queries read only the relevant files. ## Schema The dataset contains 56 variables, all stored as `string` to preserve leading zeros in IBGE municipality codes, CNES facility codes, ZIP codes, and race/ethnicity codes. Key variables include: | Variable | Description | |----------|-------------| | `dt_vacina` | Vaccination date (YYYY-MM-DD) | | `co_vacina` | Immunobiological code | | `ds_vacina` | Immunobiological description | | `co_dose` | Dose code (1st, 2nd, 3rd, booster, etc.) | | `sg_uf` | State abbreviation | | `co_municipio_ibge` | IBGE municipality code (6 digits) | | `co_cnes` | CNES health facility code | | `dt_nascimento` | Patient date of birth | | `co_sexo` | Sex (M/F) | | `co_raca_cor` | Self-reported race/ethnicity | > For the complete 56-variable data dictionary, see the Ministry of Health's > `Dicionario_tb_ria_rotina.pdf`. ## Source and processing **Original source:** Compressed JSON files from OpenDATASUS (Ministry of Health S3 bucket). **Why JSON instead of CSV?** The CSV exports from 2020–2024 contain serialization artifacts (numeric fields with `.0` suffix, loss of leading zeros). JSON preserves all values as strings with full integrity. **Processing:** JSON → NDJSON (via `jq`) → Parquet (via `polars`) → upload to R2 (via `rclone`). No transformations are applied — values are published exactly as provided by the Ministry of Health. ## Known limitations 1. **Government data, not ours.** Errors in the original data are intentionally preserved. No cleaning or correction is applied. 2. **Variable completeness.** Many fields have optional reporting and may contain high proportions of empty values or "SEM INFORMACAO". 3. **All fields are strings.** Type casting (Date, integer) must be done by the user at analysis time. 4. **Temporal coverage.** Individual-level microdata is available only from January 2020. For the 1994–2019 historical series, see the aggregated datasets: `sipni-agregados-doses` and `sipni-agregados-cobertura`. 5. **Lag.** The Ministry may take weeks to publish a given month's data. The pipeline runs monthly and reflects what is available at the source. 6. **Does not include COVID-19.** COVID vaccination data is in a separate dataset: `sipni-covid`. ## Citation ```bibtex @misc{healthbrdata, author = {Sidney da Silva Bissoli}, title = {healthbr-data: Redistribution of Brazilian Public Health Data}, year = {2026}, url = {https://huggingface.co/datasets/SidneyBissoli/sipni-microdados}, note = {Original source: Ministry of Health / OpenDATASUS} } ``` ## Contact - **GitHub:** [https://github.com/SidneyBissoli](https://github.com/SidneyBissoli) - **Hugging Face:** [https://huggingface.co/SidneyBissoli](https://huggingface.co/SidneyBissoli) - **E-mail:** sbissoli76@gmail.com --- *Last updated: 2026-02-28*

语言: - 葡萄牙语 许可协议:CC-BY 4.0 标签: - 健康 - 巴西 - 公共卫生 - Apache Parquet - OpenDATASUS - SI-PNI - 疫苗接种 - 免疫接种 美观名称:"SI-PNI——巴西常规疫苗接种微数据" 数据规模分类: - 1亿至10亿条记录 任务类别: - 表格分类 源数据集: - 原始数据集 --- # SI-PNI——巴西常规疫苗接种微数据(2020年至今) 个体级疫苗接种记录源自巴西国家免疫计划(National Immunization Program, SI-PNI),经重新分发为分区存储的Apache Parquet格式,以支持高效的分析访问。每一行对应一剂已接种的疫苗。 **本数据集隶属于[healthbr-data](https://huggingface.co/SidneyBissoli)项目**——该项目致力于开放重分发巴西公共卫生数据。 ## 数据概览 | 项目 | 详情 | |------|--------| | **官方来源** | OpenDATASUS / 巴西卫生部 | | **时间覆盖范围** | 2020年1月至今(每月更新) | | **地理覆盖范围** | 巴西全部5570个直辖市 | | **数据粒度** | 个体记录(每一行对应一剂已接种疫苗) | | **数据体量** | 7.36亿+条记录 | | **数据格式** | Apache Parquet,按`ano/mes/uf`分区 | | **数据类型** | 所有字段均存储为字符串(保留前导零) | | **更新频率** | 每月 | | **许可协议** | CC-BY 4.0 | ## 葡萄牙语摘要(已翻译) **SI-PNI——巴西常规疫苗接种微数据(2020年至今)** 本数据集源自巴西国家免疫计划信息系统(SI-PNI)的个体级常规疫苗接种微数据,经重新分发为分区存储的Apache Parquet格式,以支持高效的分析访问。每一行对应一剂已接种的疫苗。 | 项目 | 详情 | |------|--------| | **官方来源** | OpenDATASUS / 巴西卫生部 | | **时间覆盖范围** | 2020年1月至今(每月更新) | | **地理覆盖范围** | 巴西全部5570个直辖市 | | **数据粒度** | 个体记录(每一行对应一剂已接种疫苗) | | **数据体量** | 7.36亿+条记录 | | **数据格式** | Apache Parquet,按`ano/mes/uf`分区 | | **更新频率** | 每月 | > 如需查看完整的葡萄牙语文档,请参阅项目[代码仓库](https://github.com/SidneyBissoli/healthbr-data)。 ## 数据访问 数据集托管于Cloudflare R2存储服务,通过兼容S3的API进行访问。以下提供的凭据为**只读权限**,仅供公共使用。 ### R语言(Arrow库) r library(arrow) library(dplyr) Sys.setenv( AWS_ENDPOINT_URL = "https://5c499208eebced4e34bd98ffa204f2fb.r2.cloudflarestorage.com", AWS_ACCESS_KEY_ID = "28c72d4b3e1140fa468e367ae472b522", AWS_SECRET_ACCESS_KEY = "2937b2106736e2ba64e24e92f2be4e6c312bba3355586e41ce634b14c1482951", AWS_DEFAULT_REGION = "auto" ) ds <- open_dataset("s3://healthbr-data/sipni/microdados/", format = "parquet") # 示例:查询2024年1月阿克里州的疫苗接种量 ds |> filter(ano == "2024", mes == "01", uf == "AC") |> count(ds_vacina) |> collect() ### Python(PyArrow库) python import pyarrow.dataset as pds import pyarrow.fs as fs s3 = fs.S3FileSystem( endpoint_override="https://5c499208eebced4e34bd98ffa204f2fb.r2.cloudflarestorage.com", access_key="28c72d4b3e1140fa468e367ae472b522", secret_key="2937b2106736e2ba64e24e92f2be4e6c312bba3355586e41ce634b14c1482951", region="auto" ) dataset = pds.dataset( "healthbr-data/sipni/microdados/", filesystem=s3, format="parquet", partitioning="hive" ) table = dataset.to_table( filter=(pds.field("ano") == "2024") & (pds.field("uf") == "AC") ) print(table.to_pandas().head()) > **注意:** 这些凭据为只读权限,可安全用于脚本中。该存储桶不支持匿名S3访问,必须使用凭据方可访问。 ## 文件结构 s3://healthbr-data/sipni/microdados/ README.md ano=2020/ mes=01/ uf=AC/ part-0.parquet uf=AL/ part-0.parquet ... mes=02/ ... ano=2021/ ... 每个Parquet文件存储特定月份和州的接种记录。采用Hive风格的分区格式(`键=值`),可在Arrow和DuckDB中实现自动分区裁剪——过滤后的查询仅会读取相关文件。 ## 数据模式 本数据集共包含56个变量,所有字段均以字符串类型存储,以保留IBGE(巴西地理与统计研究所)直辖市代码、CNES(巴西国家医疗机构登记系统)医疗机构代码、邮政编码以及种族/族裔代码中的前导零。核心变量如下: | 变量 | 说明 | |----------|-------------| | `dt_vacina` | 疫苗接种日期(格式为YYYY-MM-DD) | | `co_vacina` | 免疫生物制剂代码 | | `ds_vacina` | 免疫生物制剂说明 | | `co_dose` | 剂次代码(首剂、第二剂、第三剂、加强针等) | | `sg_uf` | 州缩写 | | `co_municipio_ibge` | IBGE直辖市代码(6位数字) | | `co_cnes` | CNES医疗机构代码 | | `dt_nascimento` | 接种者出生日期 | | `co_sexo` | 性别(M/F) | | `co_raca_cor` | 自我报告的种族/族裔 | > 如需查看完整的56变量数据字典,请参阅巴西卫生部发布的`Dicionario_tb_ria_rotina.pdf`。 ## 源数据与处理流程 **原始数据源:** 来自OpenDATASUS(巴西卫生部S3存储桶)的压缩JSON文件。 **为何选择JSON而非CSV?** 2020年至2024年的CSV导出文件存在序列化异常(数值字段带有`.0`后缀、丢失前导零等问题)。JSON可将所有值以字符串形式存储,完整保留数据完整性。 **处理流程:** 经`jq`工具将原始JSON文件转换为NDJSON(换行分隔JSON格式),再通过`polars`库转换为Parquet格式,最后通过`rclone`上传至R2存储服务。未对数据进行任何转换——所有值均严格按照巴西卫生部提供的原始内容发布。 ## 已知局限性 1. **数据源自政府官方,非本项目所有。** 原始数据中的错误均被保留,未进行任何清洗或修正操作。 2. **变量完整性。** 多数字段为可选上报项,可能包含大量空值或“SEM INFORMACAO”(无信息)字段。 3. **所有字段均为字符串类型。** 需由使用者在分析阶段自行进行类型转换(如日期、整数类型)。 4. **时间覆盖范围。** 个体级微数据仅可追溯至2020年1月。如需1994年至2019年的历史序列数据,请参阅聚合数据集`sipni-agregados-doses`与`sipni-agregados-cobertura`。 5. **数据延迟。** 巴西卫生部可能需要数周时间才能发布当月数据。本项目的处理流程按月运行,数据内容严格反映源端当前可获取的内容。 6. **不含新冠疫苗接种数据。** 新冠疫苗接种数据已单独发布至数据集`sipni-covid`。 ## 引用格式 bibtex @misc{healthbrdata, author = {Sidney da Silva Bissoli}, title = {healthbr-data: Redistribution of Brazilian Public Health Data}, year = {2026}, url = {https://huggingface.co/datasets/SidneyBissoli/sipni-microdados}, note = {Original source: Ministry of Health / OpenDATASUS} } ## 联系方式 - **GitHub:** [https://github.com/SidneyBissoli](https://github.com/SidneyBissoli) - **Hugging Face:** [https://huggingface.co/SidneyBissoli](https://huggingface.co/SidneyBissoli) - **电子邮箱:** sbissoli76@gmail.com --- *最后更新时间:2026年2月28日*
提供机构:
SidneyBissoli
二维码
社区交流群
二维码
科研交流群
商业服务