All Projects → alephdata → countrynames

alephdata / countrynames

Licence: other
Utility library to turn country names into ISO two-letter codes

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to countrynames

Iso 3166 Countries With Regional Codes
ISO 3166-1 country lists merged with their UN Geoscheme regional codes in ready-to-use JSON, XML, CSV data sets
Stars: ✭ 1,372 (+2394.55%)
Mutual labels:  iso, countries
Countries
Countries - ISO 3166 (ISO3166-1, ISO3166, Digit, Alpha-2 and Alpha-3) countries codes and names (on eng and rus), ISO 4217 currency designators, ITU-T E.164 IDD calling phone codes, countries capitals, UN M.49 regions codes, ccTLD countries domains, IOC/NOC and FIFA letters codes, VERY FAST, NO maps[], NO slices[], NO init() funcs, NO external links/files/data, NO interface{}, NO specific dependencies, Databases/JSON/GOB/XML/CSV compatible, Emoji countries flags and currencies support, full support ISO-3166-1, ISO-4217, ITU-T E.164, Unicode CLDR and ccTLD standarts.
Stars: ✭ 85 (+54.55%)
Mutual labels:  iso, countries
Archinstall
Arch Linux installer - guided, templates etc.
Stars: ✭ 140 (+154.55%)
Mutual labels:  iso
list-of-countries
List of all countries in different formats (ISO, tld, capital, language, population)
Stars: ✭ 22 (-60%)
Mutual labels:  countries
geonames-client
GeoNames API Client
Stars: ✭ 32 (-41.82%)
Mutual labels:  countries
Isobmff
C++ Library for ISO/IEC 14496-12 - ISO Base Media File Format (QuickTime, MPEG-4, HEIF, etc)
Stars: ✭ 157 (+185.45%)
Mutual labels:  iso
bootutils
Utilities to create bootable disks, remaster ISO images, make multiboot ISO images
Stars: ✭ 18 (-67.27%)
Mutual labels:  iso
Mbp Fedora
Stars: ✭ 129 (+134.55%)
Mutual labels:  iso
Env-KB
A custom mechanical keyboard inspired by the CFTKB Mysterium utilizing the Raspberry Pi Pico
Stars: ✭ 203 (+269.09%)
Mutual labels:  iso
Unifiedarchive
UnifiedArchive - an archive manager with a unified way for different formats. Supports all basic (listing, reading, extracting and creation) and specific features (compression level, password-protection). Bundled with console program for working with archives.
Stars: ✭ 246 (+347.27%)
Mutual labels:  iso
hdx-python-country
Utilities to map between country and region codes and names and to match administrative level names from different sources. Also utilities for foreign exchange enabling obtaining current and historic FX rates for different currencies
Stars: ✭ 16 (-70.91%)
Mutual labels:  countries
Linux Unattended Installation
This project provides all you need to create an unattended installation of a minimal setup of Linux.
Stars: ✭ 215 (+290.91%)
Mutual labels:  iso
Checkn1x
Light (~50MB) images for jailbreaking iOS devices
Stars: ✭ 167 (+203.64%)
Mutual labels:  iso
geonamescache
geonamescache - a Python library for quick access to a subset of GeoNames data.
Stars: ✭ 76 (+38.18%)
Mutual labels:  countries
Tlosint Live
Trace Labs OSINT Linux Distribution based on Kali.
Stars: ✭ 151 (+174.55%)
Mutual labels:  iso
ISO8601
🎗 Super lightweight ISO8601 Date Formatter in Swift
Stars: ✭ 20 (-63.64%)
Mutual labels:  iso
Installer
不进bios和阵列卡,不用外部工具也不用买出厂服务,只需要开机,物理服务器便批量自动做硬raid和安装系统以及设置各自的所有网络信息和设置
Stars: ✭ 138 (+150.91%)
Mutual labels:  iso
Geoportal Server
Geoportal Server is a standards-based, open source product that enables discovery and use of geospatial resources including data and services.
Stars: ✭ 210 (+281.82%)
Mutual labels:  iso
country-flags
A small package to convert a country code to the corresponding country flag emoji
Stars: ✭ 27 (-50.91%)
Mutual labels:  countries
date-extractor
Extract dates from text
Stars: ✭ 58 (+5.45%)
Mutual labels:  iso

countrynames

build

This library helps with the mapping of country names to their respective two or three letter codes. The idea is to incorporate common names for countries, and even some limited misspellings, as they occur in source data.

There is also support for fuzzy matching, which uses a heuristic based on Levenshtein distance.

Usage

import countrynames

assert 'DE' == countrynames.to_code('Germany')
assert 'DE' == countrynames.to_code('Bundesrepublik Deutschland')
assert 'DE' == countrynames.to_code('Bundesrepublik Deutschlan', fuzzy=True)
assert 'DE' == countrynames.to_code('DE')
assert 'DEU' == countrynames.to_code_3('Germany')

Non-standard country codes

  • XK or XKX - Kosovo
  • EU or EUU - European Union

For some dissolved countries (e.g. SUHH for Soviet Union) and sub-regions (e.g. GB-SCT for Scotland) special codes are defined and returned from both to_code and to_code_3.

License

The MIT License (MIT)

Copyright (c) 2016 Friedrich Lindenberg

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].