{"id":18354495,"url":"https://github.com/alvarofpp/dataset-flights-brazil","last_synced_at":"2025-04-06T12:31:49.979Z","repository":{"id":132916957,"uuid":"387572680","full_name":"alvarofpp/dataset-flights-brazil","owner":"alvarofpp","description":"Flights in Brazil registered by ANAC (Agência Nacional de Aviação Civil - National Civil Aviation Agency).","archived":false,"fork":false,"pushed_at":"2024-02-24T21:27:09.000Z","size":100996,"stargazers_count":10,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-21T23:51:12.133Z","etag":null,"topics":["air-traffic","air-traffic-data","brazil","csv","dataset","flights","graphml","python3"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alvarofpp.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2021-07-19T19:26:19.000Z","updated_at":"2024-11-25T13:02:46.000Z","dependencies_parsed_at":"2024-02-24T22:40:24.315Z","dependency_job_id":null,"html_url":"https://github.com/alvarofpp/dataset-flights-brazil","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alvarofpp%2Fdataset-flights-brazil","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alvarofpp%2Fdataset-flights-brazil/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alvarofpp%2Fdataset-flights-brazil/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alvarofpp%2Fdataset-flights-brazil/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alvarofpp","download_url":"https://codeload.github.com/alvarofpp/dataset-flights-brazil/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247484320,"owners_count":20946384,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["air-traffic","air-traffic-data","brazil","csv","dataset","flights","graphml","python3"],"created_at":"2024-11-05T22:04:17.725Z","updated_at":"2025-04-06T12:31:48.276Z","avatar_url":"https://github.com/alvarofpp.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Flights in Brazil\n\nThis repository have datasets with all flights in Brazil registered by ANAC\n(Agência Nacional de Aviação Civil - National Civil Aviation Agency), all airports\ninvolved in these flights and a undirected graph with the number of flights between two airports.\n\nSources:\n\n- [Flights in Brazil by ANAC](https://www.gov.br/anac/pt-br/assuntos/dados-e-estatisticas/dados-estatisticos).\n- [List of public aerodromes by ANAC](https://www.anac.gov.br/acesso-a-informacao/dados-abertos/areas-de-atuacao/aerodromos/lista-de-aerodromos-publicos-v2).\n- [Airport Codes by DataHub.io](https://datahub.io/core/airport-codes)\n  (note: the latitude and longitude columns have their values swapped).\n\nAfter merging the datasets, the [geocoder](https://github.com/DenisCarriere/geocoder)\npackage was used to fill in the empty values.\n\n## Datasets\n\nYou can find the datasets in `data/`.\n\n### [`anac.csv.lrz`](data/anac.csv.lrz)\n\nAll flights in Brazil by ANAC. ANAC does not provide the data dictionary.\nYou can use `lrzip` to decompress the file.\n\n### [`airports.csv`](data/airports.csv)\n\nAll airports on ANAC flight records.\n\n| Column | Type | Description | Example |\n| --- | --- | --- | --- |\n| code | `string` | [ICAO airport code](https://en.wikipedia.org/wiki/ICAO_airport_code) | `\"SNBG\"` |\n| name | `string` | Airport name. | `\"BAIXO GUANDU\"` |\n| state | `string` | State where the airport is located. | `\"ES\"` |\n| region | `string` | Region where the airport is located. | `\"SUDESTE\"` |\n| country | `string` | Country where the airport is located. | `\"BRASIL\"` |\n| continent | `string` | Continent where the airport is located. | `\"AMÉRICA DO SUL\"` |\n| lat_geo_point | `double` | Latitude of the airport reference point. | `-19.498889` |\n| lon_geo_point | `double` | Longitude of the airport reference point. | `-41.041944` |\n\n### [`air_traffic.graphml`](data/air_traffic.graphml)\n\nIt's an undirected graph.\n\n#### Node attributes\n\nThe id of each node is the ICAO airport code.\n\n| Column | Type | Description | Example |\n| --- | --- | --- | --- |\n| name | `string` | Airport name. | `\"GUARULHOS\"` |\n| country | `string` | Country where the airport is located. | `\"BRASIL\"` |\n| latitude | `double` | Latitude of the airport reference point. | `-23.435556` |\n| longitude | `double` | Longitude of the airport reference point. | `-46.473056` |\n\n#### Edge attributes\n\n| Column | Type | Description | Example |\n| --- | --- | --- | --- |\n| flight_count | `int` | Number of flights carried out between these airports. | `147` |\n\n## Scripts\n\n- `extract.py` - Download all CSV files and puts them in the `data/extract` folder.\n- `transform_to_anac_csv.py` - Merges all files downloaded from ANAC, rename the columns and create `anac.csv`.\n- `transform_to_airports_csv.py` - Creates a dataset with all airports (`airports.csv`).\n- `transform_to_graphml.py` - Creates an undirected graph (`air_traffic.graphml`).\n\n## Generate\n\nIn your environment:\n\n```shell\n# Install requirements for scripts\npip install -r requirements.txt\n\n# Download csv files from sources\npython3 extract.py\n\n# Transform to final files\npython3 transform_to_anac_csv.py\npython3 transform_to_airports_csv.py\npython3 transform_to_graphml.py\n```\n\nIf you have Docker and Makefile installed on your machine,\nyou can execute the `make build` command to create the image,\nfollowed by `make shell` to access a container and execute\nthe aforementioned steps to generate the files.\n\nTo convert the `data/anac.csv` file into `data/anac.csv.lrz`, you must execute the following commands:\n\n```shell\nsudo apt install lrzip\nlrzip -z data/anac.csv\n```\n\n## Contributing\n\nContributions are more than welcome. Fork, improve and make a pull request.\nFor bugs, ideas for improvement or other, please create an\n[issue](https://github.com/alvarofpp/dataset-flights-brazil/issues).\n\n## License\n\nThis project is licensed under the CDLA-Sharing-1.0 License - see the [LICENSE](LICENSE)\nfile for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falvarofpp%2Fdataset-flights-brazil","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falvarofpp%2Fdataset-flights-brazil","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falvarofpp%2Fdataset-flights-brazil/lists"}