Saravanan666/pypi-org huggingface dataset:
Package: k3modutil
k3modutilSubmodule Utilities.k3modutil is a component ofpykit3project: a python3 toolkit set.Submodule Utilities.Installpip install k3modutilSynopsisimportk3modutilimportpykitk3modutil.submodules(pykit)# {#    'modutil': <module> pykit.modutil,#    ... ...# }k3modutil.submodule_tree(pykit)# {#    'modutil': {'module': <module> pykit.modutil,#                'children': {#                            'modutil': {#                                    'module': <module> pykit.modutil.modutil,#                                    'children': None,#                                    },#                            'test': {#                                    'module': <module> pykit.modutil.test,#                                    'children': {#                                        'test_modutil': {#                                            'module': <module> pykit.modutil.test.test_modutil,#                                            'children': None,#                                        },#                                    },#                            }#                },#               }#    ... ...# }k3modutil.submodule_leaf_tree(pykit)# {#    'modutil': {#                'modutil': <module> pykit.modutil.modutil,#                'test': {'test_modutil': <module> pykit.modutil.test.test_modutil},#                }#    ... ...# }AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3net
k3netUtility functions for network related operation.k3net is a component ofpykit3project: a python3 toolkit set.Utility functions for network related operation.Installpip install k3netAuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3num
k3numConvert number to human readable format in a string.k3num is a component ofpykit3project: a python3 toolkit set.k3num convert numbers(or numbers indictorlist) to human readable
format in string::>>> readable(103425)
'101.0K'
>>> readable({ 'total': 10240, 'progress': [1, 1024*2.1, 1024*3.2], })
{'total': '10K', 'progress': ['1', '2.10K', '3.20K']}
>>> parsenum('5.2K')
5324.8
>>> parsenum('10%')
0.1Attributes:
value_to_unit(dict): map of int to unit, e.g.:1024 -> "K",1024² -> "M".Usage::

        >>> value_to_unit[1024**2]
        'M'

        >>> unit_to_value['K']
        1024

unit_to_value(dict): reverse map of `value_to_unit`.k3num.Hex provides hex integer with arithmatic support.Different ways to create a 4-byte crc32 hex str::>>> Hex(0x0102, 4)
'00000102'
>>> Hex(0x0102, 'crc32')
'00000102'
>>> Hex.crc32(0x0102)
'00000102'
>>> Hex('00000102', 'crc32')
'00000102'
>>> Hex.crc32('00000102')
'00000102'Create with a tuple of prefix and a filling byte::>>> Hex(('12', 1), 'crc32')
'12010101'Arithmetic operations::>>> Hex(0x0102, 'crc32') + 1
'00000103'
>>> Hex(0x0102, 'crc32') * 2
'00000204'
>>> Hex(0x0102, 'crc32') - 1000000
'00000000'
>>> Hex(0x0102, 'crc32') * 1000000000
'ffffffff'Iterate over sha1 space with a specific step::>>> Hex.sha1(0) + Hex.sha1(('10', 0))
'1000000000000000000000000000000000000000'
>>> Hex.sha1(0) + Hex.sha1(('10', 0)) * 2
'2000000000000000000000000000000000000000'Installpip install k3numSynopsis>>>readable(103425)'101.0K'>>>readable({'total':10240,'progress':[1,1024*2.1,1024*3.2],}){'total':'10K','progress':['1','2.10K','3.20K']}>>>parsenum('5.2K')5324.8>>>parsenum('10%')0.1>>>value_to_unit[1024**2]'M'>>>unit_to_value['K']1024>>>Hex(0x0102,4)'00000102'>>>Hex(0x0102,'crc32')'00000102'>>>Hex.crc32(0x0102)'00000102'>>>Hex('00000102','crc32')'00000102'>>>Hex.crc32('00000102')'00000102'>>>Hex(('12',1),'crc32')'12010101'>>>Hex(0x0102,'crc32')+1'00000103'>>>Hex(0x0102,'crc32')*2'00000204'>>>Hex(0x0102,'crc32')-1000000'00000000'>>>Hex(0x0102,'crc32')*1000000000'ffffffff'>>>Hex.sha1(0)+Hex.sha1(('10',0))'1000000000000000000000000000000000000000'>>>Hex.sha1(0)+Hex.sha1(('10',0))*2'2000000000000000000000000000000000000000'AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3pattern
k3patternFind common prefix of severalstrings, tuples of string, or other nested structure, recursively by default.k3pattern is a component ofpykit3project: a python3 toolkit set.Find common prefix of several string, tuples of string, or other nested structure, recursively by default.
It returns the shortest prefix: empty string or empty tuple is removed.Installpip install k3patternSynopsisimportk3patternk3pattern.common_prefix('abc','abd')# 'ab'k3pattern.common_prefix((1,2,'abc'),(1,2,'abd'))# (1, 2, 'ab')k3pattern.common_prefix((1,2,'abc'),(1,2,'xyz'))# (1, 2); empty prefix of 'abc' and 'xyz' is removedk3pattern.common_prefix((1,2,(5,6)),(1,2,(5,7)))# (1, 2, (5,) )k3pattern.common_prefix('abc','abd','abe')# 'ab'; common prefix of more than twoAuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3portlock
k3portlockk3portlock is a cross-process lock that is implemented withtcpport binding.k3portlock is a component ofpykit3project: a python3 toolkit set.k3portlock is a cross-process lock that is implemented withtcpport binding.
Since no two processes could bind on a same TCP port.k3portlock tries to bind3ports on loopback ip127.0.0.1.
If a k3portlock instance succeeds on binding2ports out of 3,
it is considered this instance has acquired the lock.Installpip install k3portlockAuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3priorityqueue
k3priorityqueuepriorityQueue is a queue with priority supportk3priorityqueue is a component ofpykit3project: a python3 toolkit set.PriorityQueue is a queue with priority support:The numbers of items it pops from each producer matches exactly the ratio of their priority:
If the priorities of 3 producer A, B and C are 1, 3 and 7, and it runs long
enough, it is expected that the number of items popped from A, B and C are
1:3:7.import k3priorityqueueproducers = (
# id, priority, iterable
(1, 1, [1] * 10),
(2, 2, [2] * 10),
(3, 3, [3] * 10),
)
pq = k3priorityqueue.PriorityQueue()
for pid, prio, itr in producers:
pq.add_producer(pid, prio, itr)count = {}
for _ in range(12):
val = pq.get()
count[val] = count.get(val, 0) + 1
print(val)print('respect priority ratio: counts:', repr(count))while True:
try:
val = pq.get()
except k3priorityqueue.Empty as e:
break
count[val] = count.get(val, 0) + 1
print(val)print('consumed all: counts:', repr(count))Installpip install k3priorityqueueSynopsisimportk3priorityqueueproducers=(# id, priority, iterable(1,1,[1]*10),(2,2,[2]*10),(3,3,[3]*10),)pq=k3priorityqueue.PriorityQueue()forpid,prio,itrinproducers:pq.add_producer(pid,prio,itr)count={}for_inrange(12):val=pq.get()count[val]=count.get(val,0)+1print(val)print('respect priority ratio: counts:',repr(count))whileTrue:try:val=pq.get()exceptk3priorityqueue.Emptyase:breakcount[val]=count.get(val,0)+1print(val)print('consumed all: counts:',repr(count))AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3proc
k3proceasy to usePopenk3proc is a component ofpykit3project: a python3 toolkit set.k3proc is utility to create sub process.Execute a shell script::>>> returncode, out, err = k3proc.shell_script('ls / | grep bin')Run a command::# Unlike the above snippet, following statement does not start an sh process.
returncode, out, err = k3proc.command('ls', 'a*', cwd='/usr/local')Installpip install k3procSynopsis>>>returncode,out,err=k3proc.shell_script('ls / | grep bin')AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3rangeset
k3rangesetsegmented range which is represented in a list of sorted interleaving range.k3rangeset is a component ofpykit3project: a python3 toolkit set.Segmented range which is represented in a list of sorted interleaving range.A range set can be thought as:[[1, 2], [5, 7]].Installpip install k3rangesetSynopsisimportk3rangeseta=k3rangeset.RangeSet([[1,5],[10,20]])a.has(1)# Truea.has(8)# Falsea.add([5,7])# [[1, 7], [10, 20]]inp=[[0,1,[['a','b','ab'],['b','d','bd'],]],[1,2,[['a','c','ac'],['c','d','cd'],]],]r=k3rangeset.RangeDict(inp,dimension=2)print(r.get(0.5,'a'))# 'ab'print(r.get(1.5,'a'))# 'ac'AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3redisutil
k3redisutilFor using redis more easily.k3redisutil is a component ofpykit3project: a python3 toolkit set.For using redis more easily.Installpip install k3redisutilSynopsisimportk3redisutilimporttime# Using redis as a duplex cross process communication channel pool.# client and server with the same channel name "/foo" is a pairc=k3redisutil.RedisChannel(6379,'/foo','client')s=k3redisutil.RedisChannel(6379,'/foo','server')c.send_msg('c2s')s.send_msg('s2c')# list channelsprint(c.list_channel('/'))# ["/foo"]print(s.recv_msg())# c2sprint(c.recv_msg())# s2ccli=k3redisutil.RedisProxyClient([('127.0.0.1',2222),('192.168.0.100',222)])cli.set('k1','v1',retry=1)cli.set('k2','v2',expire=1000)# msecprint(cli.get('k1',retry=2))# out: 'v1'print(cli.get('k2'))# out: 'v2'time.sleep(1)cli.get('k2')# raise a 'redisutil.KeyNotFoundError' because it is timeoutcli.hset('hashname1','k3','v3')cli.hset('hashname2','k4','v4',expire=1000)print(cli.hget('hashname1','k3'))# out: 'v3'print(cli.hget('hashname2','k4'))# out: 'v4'time.sleep(1)cli.hget('hashname2','k4')# raise a 'redisutil.KeyNotFoundError' because it is timeoutAuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3shell
k3shellA python module to manage commands.k3shell is a component ofpykit3project: a python3 toolkit set.Namek3shellStatusThe library is considered production ready.Installpip install k3shellSynopsisimportk3shellimportsysarguments={'echo_repr':(lambdax:sys.stdout.write(repr(x)),('x',{'nargs':'+','help':'just an input message'}),),'foo':{'bar':lambda:sys.stdout.write('bar'),'bob':{'plus':(lambdax,y:sys.stdout.write(str(x+y)),('x',{'type':int,help:'an int is needed'}),('y',{'type':int,help:'an int is needed'}),),},},'__add_help__':{('echo_repr',):'output what is input.',('foo','bar',):'print a "bar".',('foo','bob','plus',):'do addition operation with 2 numbers.',},'__description__':'this is an example command.',}k3shell.command(**arguments)"""then you can execute your command as:python demo.py echo_repr hello!# 'hello!'python demo.py foo bar# 'bar'python demo.py foo bob plus 1 2# 3and you can get a usage help message like:$ python demo.py -h---------------------------usage: demo.py [-h] {echo_repr, foo bar, foo bob plus} ...this is an example command.positional arguments:{echo_repr, foo bar, foo bob plus} commands to select ...echo_repr            output what is input.foo bar              print a "bar".foo bob plus         do addition operation with 2 numbers.optional arguments:-h, --help           show this help message and exit$ python demo.py foo bob plus -h--------------------------usage: demo.py foo bob plus [-h] x ypositional arguments:x   an int is needy   an int is needoptional arguments:-h, --help           show this help message and exit"""AuthorWenbo Li(李文博)wenbo.li@baishancloud.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2017 Wenbo Li(李文博)wenbo.li@baishancloud.com
Package: k3stopwatch
k3stopwatchStopWatch - library for adding timers and tags in your code for performance monitoringk3stopwatch is a component ofpykit3project: a python3 toolkit set.StopWatch operates on a notion of "spans" which represent scopes of code for which we
want to measure timing. Spans can be nested and placed inside loops for aggregation.StopWatch requires a root scope which upon completion signifies the end of the round
of measurements. On a server, you might use a single request as your root scope.StopWatch produces two kinds of reports.Aggregated (see _reported_values).Non-aggregated or "tracing" (see _reported_traces).Installpip install k3stopwatchSynopsisimportk3stopwatchsw=k3stopwatch.StopWatch()withsw.timer('rwoot'):foriinrange(50):withsw.timer('inner_task'):print("do_inner_task(i)")AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3str
k3strk3str is a collection of string utilities.k3str is a component ofpykit3project: a python3 toolkit set.Installpip install k3strSynopsis>>>repr(to_bytes('我'))"b'\\xe6\\x88\\x91'"AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3stubproxy
k3stubproxyAn proxy implementation to be used by embedded c stub implementationsStub generationUse the cli tool k3stubproxy-generate-stub included in this package.Requirements:Stub functions begin with externIn the code documnetation a parameter is labled in/out in the following styleparam [in] variableNameparam [out] variableNameExample CLI Usagek3stubproxy-generate-stub -v ../Code/HAL/HAL_*.c --func_prefix HAL_ -o ../Code/HAL/high_level_stub/ --filename_suffix _teststub --file_header defheader.txt --stub_function_definition_out stub_function_definition.jsonOther CLI Tools (Version 0.2.1)k3stubproxy-generate-target-stub (Generate a python target stub using the stub function definition created by k3stubproxy-generate-stubk3stubproxy-analyse-stub-function-definition (Given the stub function definition, show stub functions and used input, output and return types)Example usage within CC API usage#include"Stub_Connector_Interface.h"...ifinitStubConnector(NULL)!=0{// errorreturn1;}Provide Implementations for the following functions:PyObject*convert_input_to_python_object(va_listvalist,intparameterPos,char*typeString);intconvert_python_object_to_output(va_listvalist,intparameterPos,char*typeString,PyObject*outputObject);And include the files Stub_Connector_Implementation.c,Stub_Connector_Interface.h from within k3stubproxy/c_stub and the replace the standard implementation with generated stub when compiling and linking.General Information About Embedding Python Within Cchar*phDir="/some/path/to/a/venv";printf("INFO: Using virutalenv: %s",phDir);// This should not be some hard code palth like /home/annoying_user/temp/project123// For example in some usages of the k3stubproxy this is set dynamically to look// beside the exe vor the venv// Note: Need to check return of Py_DecodeLocale is != NULLPy_SetPythonHome(Py_DecodeLocale(phDir,NULL));//optional but recommendedwchar_t*program=Py_DecodeLocale("stub_program",NULL);Py_SetProgramName(program);Py_Initialize();// Then any lib within the venv can be used via cpythonPyRun_SimpleString("import k3stubproxy;");
Package: k3testdocumentation-generator
k3testdocumentation-generatorTool for generating test documentation & test coverage out of a file/folder hierarchy (or an equivalent json file).
A default file/folder hierarchy is defined below with which the tool will work without customisations/custom templates.Tool for generationg the Documentation:k3testdocumentation-generatorTool for generationg the Coverage:k3testdocumentation-generate-coverageInstallation (use within viruatlenv or equivalent)pip install k3testdocumentation-generatorPrerequisites/Limitations:When generating PDFs from HTML wkhtmltopdfneedsto be installed (required by the pdfkit library). It is available in the package managers of the common linux distributions.May require running a virtual X server on a headless environment.When generating PDFs from LATEX pdflatexneedsto be installed. It is also available in the package managers of the common linux distributions.Default File/Folder HierarchyCreate a the test directory structure (example included in src).
This structure works with the inbuilt template. To support a different
structure create a custom template and pass it using the --template parameter.

Note: any json file will be opened and interpreted. In the default structure
all json files need contain a list of strings 

example_test_dir/
├── TC.XX.01
│   ├── precondition.md
│   ├── required_equiptment.json
│   ├── requirements_fully_tested.json
│   ├── requirements_partially_tested.json
│   ├── test_description.md
│   └── test_name.txt
└── TC.XX.02
    ├── test_descrition.md
    └── __test__.json (Abbreviated form allowing the direct instanciation of
                       keys in one file. Will be overwritten if the file also
                       exists)Corresponding k3testdocumentation-generator command:k3testdocumentation-generator example_test_dir/ -v -o output.pdfCorresponding k3testdocumentation-generate-coverage command:and a required json file exists with requirements in the folling format["R1","R2","P1","P2"]k3testdocumentation-generate-coverage requirements_list.json example_test_dir/ -v -o output.pdf
Package: k3thread
k3threadutility to create thread.k3thread is a component ofpykit3project: a python3 toolkit set.k3thread is utility to create and operate thread.Start a daemon thread after 0.2 seconds::>>> th = daemon(lambda :1, after=0.2)Stop a thread by sending a exception::import time

def busy():
    while True:
        time.sleep(0.1)

t = daemon(busy)
send_exception(t, SystemExit)Installpip install k3threadSynopsis>>>th=daemon(lambda:1,after=0.2)AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3time
k3timeTime convertion utilsk3time is a component ofpykit3project: a python3 toolkit set.Installpip install k3timeSynopsis>>>parse('2017-01-24T07:51:59.000Z','iso')datetime.datetime(2017,1,24,7,51,59)>>>format_ts(1485216000,'iso')'2017-01-24T00:00:00.000Z'>>>format_ts(1485216000,'%Y-%m-%d')'2017-01-24'AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3txutil
k3txutilA collection of helper functions to implement transactional operations.k3txutil is a component ofpykit3project: a python3 toolkit set.NametxutilStatusThis library is considered production ready.DescriptionA collection of helper functions to implement transactional operations.ExceptionsCASConflictsyntax:CASConflict()User should raise this exception when a CAS conflict detect in a user definedsetfunction.Installpip install k3txutilSynopsisimportk3txutilimportthreadingclassFoo(object):def__init__(self):self.lock=threading.RLock()self.val=0self.ver=0def_get(self,db,key,**kwargs):# db, key == 'dbname', 'mykey'withself.lock:returnself.val,self.verdef_set(self,db,key,val,prev_stat,**kwargs):# db, key == 'dbname', 'mykey'withself.lock:ifprev_stat!=self.ver:raisek3txutil.CASConflict(prev_stat,self.ver)self.val=valself.ver+=1deftest_cas(self):forcurrink3txutil.cas_loop(self._get,self._set,args=('dbname','mykey',)):curr.v+=2print((self.val,self.ver))# (2, 1)whileTrue:curr_val,stat=getter(key="mykey")new_val=curr_val+':foo'try:setter(new_val,stat,key="mykey")exceptCASConflict:continueelse:break#`cas_loop` simplifies the above workflow to:forcurrink3txutil.cas_loop(getter,setter,args=("mykey",)):curr.v+=':foo'AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3ut
k3utunittest utilk3ut is a component ofpykit3project: a python3 toolkit set.Installpip install k3utSynopsisAuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3utdocker
k3utdockerunit test for python-dockerk3utdocker is a component ofpykit3project: a python3 toolkit set.Installpip install k3utdockerSynopsisAuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3utfjson
k3utfjsonforcejson.dumpandjson.loadinutf-8encoding.k3utfjson is a component ofpykit3project: a python3 toolkit set.Nameutfjson: forcejson.dumpandjson.loadinutf-8encoding.StatusThis library is considered production ready.Installpip install k3utfjsonSynopsisimportk3utfjsonk3utfjson.load('"hello"')k3utfjson.dump({})AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k3zkutil
k3zkutilSome helper function to make life easier with zookeeper.k3zkutil is a component ofpykit3project: a python3 toolkit set.Some helper function to make life easier with zookeeper.Installpip install k3zkutilSynopsisfromk3zkutilimportconfig"""config.zk_acl      # (('xp', '123', 'cdrwa'), ('foo', 'bar', 'rw'))config.zk_auth     # ('digest', 'xp', '123')config.zk_hosts    # '127.0.0.1:2181'config.zk_node_id  # 'web-01'config.zk_lock_dir # 'lock/'"""withk3zkutil.ZKLock('foo_lock',zkconf=dict(hosts='127.0.0.1:2181',acl=(('xp','123','cdrwa'),),auth=('digest','xp','123'),node_id='web-3',lock_dir='my_locks/')):print("do something")lock=k3zkutil.ZKLock('foo')try:forholder,verinlock.acquire_loop(timeout=3):print('lock is currently held by:',holder,ver)print('lock is acquired')exceptk3zkutil.LockTimeoutase:print('timeout to acquire "foo"')AuthorZhang Yanpo (张炎泼)drdr.xp@gmail.comCopyright and LicenseThe MIT License (MIT)Copyright (c) 2015 Zhang Yanpo (张炎泼)drdr.xp@gmail.com
Package: k4
K4K4 is a terminal based UI to interact with your Kafka clusters.Roadmapkafka_wrapperaclbrokertest brokerconsumeconsumer groups/offsetstest consumer groups/offsetspartitionproducertopictest topick4~/.config/k4config10 bit custom colorswindowscommand inputscrolling -https://github.com/mingrammer/python-curses-scroll-exampleresizingscreenscreen managercontent row editcontent row describepoc edit ini config using default terminal editor. see examples/kafka_wrapper/topics.pyWish Listproducerconsumerschema registrykafka connectquery JMX metrics for and display to users. disk size, bytes-in, bytes-out, etc.https://github.com/dgildeh/JMXQuery/tree/master/pythonInstallpipinstallk4ExamplesTODOLicenseApache 2.0 License - aidanmelen/k4
Package: k4a
Azure-Kinect-PythonPython 3 bindings for the Azure Kinect SDKChangelogv1.1.0: Updated supported SDK and firmware versions to latestv1.0.0: Initial releaseSetupInstall the right Kinect SDK, Kinect Body Tracking SDK, and device firmware versionsPlease uninstall all unrelated SDK versions if you are having issues. The supported versions are:Sensor SDK v1.4.1Body tracking SDK v1.0.1Device firmware version must be at least 1.6.110079014 or higher.Add the following to your system PATH:C:\Program Files\Azure Kinect SDK v1.4.1\sdk\windows-desktop\amd64\release\binC:\Program Files\Azure Kinect Body Tracking SDK\sdk\windows-desktop\amd64\release\binC:\Program Files\Azure Kinect Body Tracking SDK\tools(Or relevant paths for your platform containing the thek4a(.so|.dll)andk4abt(.so|.dll)dynamic libraries)Feature supportCurrently only body tracking is wrapped, but adding further wrappings should be easy and PRs would be appreciated!ExamplesThere is a very simple example you can run via:py-3example/simple_sample.pyDemosWe are using it to develop an Azure Kinect plugin forBlender, which you can see a very early demo of here:The plugin is available for early access and will be open-sourced soon, please emailstephen@hexops.comto gain early access.TroubleshootingDo NOT use Python from the Windows StoreIf you get the error:[2021-01-18 14:05:28.307] [error] [t=6336] [K4ABT] D:\a\1\s\src\TrackerHost\TrackerHost.cpp (157): Create(). Find onnxruntime.dll at C:\Program Files\Azure Kinect Body Tracking SDK\tools\onnxruntime.dll but it doesn't load correctly!It is because the Windows Store installs Python to a restricted user directory which cannot access external DLLs.