1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5
6 unittestCheckHook,
7
8 setuptools,
9
10 unicodecsv,
11 pyyaml,
12 regex,
13 numpy,
14 editdistance,
15 munkres,
16 pandas,
17 levenshtein,
18}:
19
20buildPythonPackage rec {
21 pname = "panphon";
22 version = "0.22.2";
23 pyproject = true;
24
25 src = fetchPypi {
26 inherit pname version;
27 hash = "sha256-OD1HfVh/66HKWoKHjiT+d8FkXW++ngHJ6X1JjYopujU=";
28 };
29
30 build-system = [ setuptools ];
31
32 dependencies = [
33 unicodecsv
34 pyyaml
35 regex
36 numpy
37 editdistance
38 munkres
39 pandas
40 levenshtein # need for align_wordlists.py script
41 ];
42
43 nativeCheckInputs = [ unittestCheckHook ];
44
45 unittestFlagsArray = [
46 "-s"
47 "test"
48 ];
49
50 pythonImportsCheck = [
51 "panphon"
52 "panphon.segment"
53 "panphon.distance"
54 ];
55
56 meta = with lib; {
57 description = "Tools for using the International Phonetic Alphabet with phonological features";
58 homepage = "https://github.com/dmort27/panphon";
59 license = licenses.mit;
60 maintainers = with maintainers; [ vizid ];
61 };
62}