kinfer 0.3.3__cp312-cp312-macosx_11_0_arm64.whl → 0.4.1__cp312-cp312-macosx_11_0_arm64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. kinfer/__init__.py +0 -5
  2. kinfer/common/__init__.py +0 -0
  3. kinfer/common/types.py +12 -0
  4. kinfer/export/common.py +41 -0
  5. kinfer/export/jax.py +53 -0
  6. kinfer/export/pytorch.py +45 -110
  7. kinfer/export/serialize.py +93 -0
  8. kinfer/requirements.txt +3 -4
  9. kinfer/rust/Cargo.toml +20 -8
  10. kinfer/rust/src/lib.rs +2 -11
  11. kinfer/rust/src/model.rs +286 -121
  12. kinfer/rust/src/runtime.rs +104 -0
  13. kinfer/rust_bindings/Cargo.toml +8 -1
  14. kinfer/rust_bindings/rust_bindings.pyi +36 -0
  15. kinfer/rust_bindings/src/lib.rs +326 -1
  16. kinfer/rust_bindings.cpython-312-darwin.so +0 -0
  17. kinfer/rust_bindings.pyi +30 -1
  18. kinfer-0.4.1.dist-info/METADATA +55 -0
  19. kinfer-0.4.1.dist-info/RECORD +26 -0
  20. {kinfer-0.3.3.dist-info → kinfer-0.4.1.dist-info}/WHEEL +2 -1
  21. kinfer/inference/__init__.py +0 -2
  22. kinfer/inference/base.py +0 -64
  23. kinfer/inference/python.py +0 -66
  24. kinfer/proto/__init__.py +0 -40
  25. kinfer/proto/kinfer_pb2.py +0 -103
  26. kinfer/proto/kinfer_pb2.pyi +0 -1097
  27. kinfer/requirements-dev.txt +0 -8
  28. kinfer/rust/build.rs +0 -16
  29. kinfer/rust/src/kinfer_proto.rs +0 -14
  30. kinfer/rust/src/main.rs +0 -6
  31. kinfer/rust/src/onnx_serializer.rs +0 -804
  32. kinfer/rust/src/serializer.rs +0 -221
  33. kinfer/rust/src/tests/onnx_serializer_tests.rs +0 -212
  34. kinfer/serialize/__init__.py +0 -60
  35. kinfer/serialize/base.py +0 -536
  36. kinfer/serialize/json.py +0 -399
  37. kinfer/serialize/numpy.py +0 -426
  38. kinfer/serialize/pytorch.py +0 -402
  39. kinfer/serialize/schema.py +0 -125
  40. kinfer/serialize/types.py +0 -17
  41. kinfer/serialize/utils.py +0 -177
  42. kinfer-0.3.3.dist-info/METADATA +0 -57
  43. kinfer-0.3.3.dist-info/RECORD +0 -40
  44. {kinfer-0.3.3.dist-info → kinfer-0.4.1.dist-info/licenses}/LICENSE +0 -0
  45. {kinfer-0.3.3.dist-info → kinfer-0.4.1.dist-info}/top_level.txt +0 -0
@@ -1,103 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- # Generated by the protocol buffer compiler. DO NOT EDIT!
3
- # NO CHECKED-IN PROTOBUF GENCODE
4
- # source: kinfer/proto/kinfer.proto
5
- # Protobuf Python Version: 5.29.1
6
- """Generated protocol buffer code."""
7
-
8
- from google.protobuf import descriptor as _descriptor
9
- from google.protobuf import descriptor_pool as _descriptor_pool
10
- from google.protobuf import runtime_version as _runtime_version
11
- from google.protobuf import symbol_database as _symbol_database
12
- from google.protobuf.internal import builder as _builder
13
-
14
- _runtime_version.ValidateProtobufRuntimeVersion(
15
- _runtime_version.Domain.PUBLIC, 5, 29, 1, "", "kinfer/proto/kinfer.proto"
16
- )
17
- # @@protoc_insertion_point(imports)
18
-
19
- _sym_db = _symbol_database.Default()
20
-
21
-
22
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
23
- b'\n\x19kinfer/proto/kinfer.proto\x12\x0ckinfer.proto"f\n\x12JointPositionValue\x12\x12\n\njoint_name\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x02\x12-\n\x04unit\x18\x03 \x01(\x0e\x32\x1f.kinfer.proto.JointPositionUnit"Z\n\x14JointPositionsSchema\x12-\n\x04unit\x18\x01 \x01(\x0e\x32\x1f.kinfer.proto.JointPositionUnit\x12\x13\n\x0bjoint_names\x18\x02 \x03(\t"G\n\x13JointPositionsValue\x12\x30\n\x06values\x18\x01 \x03(\x0b\x32 .kinfer.proto.JointPositionValue"f\n\x12JointVelocityValue\x12\x12\n\njoint_name\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x02\x12-\n\x04unit\x18\x03 \x01(\x0e\x32\x1f.kinfer.proto.JointVelocityUnit"[\n\x15JointVelocitiesSchema\x12-\n\x04unit\x18\x01 \x01(\x0e\x32\x1f.kinfer.proto.JointVelocityUnit\x12\x13\n\x0bjoint_names\x18\x02 \x03(\t"H\n\x14JointVelocitiesValue\x12\x30\n\x06values\x18\x01 \x03(\x0b\x32 .kinfer.proto.JointVelocityValue"b\n\x10JointTorqueValue\x12\x12\n\njoint_name\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x02\x12+\n\x04unit\x18\x03 \x01(\x0e\x32\x1d.kinfer.proto.JointTorqueUnit"V\n\x12JointTorquesSchema\x12+\n\x04unit\x18\x01 \x01(\x0e\x32\x1d.kinfer.proto.JointTorqueUnit\x12\x13\n\x0bjoint_names\x18\x02 \x03(\t"C\n\x11JointTorquesValue\x12.\n\x06values\x18\x01 \x03(\x0b\x32\x1e.kinfer.proto.JointTorqueValue"\xce\x01\n\x13JointCommandsSchema\x12\x13\n\x0bjoint_names\x18\x01 \x03(\t\x12\x32\n\x0btorque_unit\x18\x02 \x01(\x0e\x32\x1d.kinfer.proto.JointTorqueUnit\x12\x36\n\rvelocity_unit\x18\x03 \x01(\x0e\x32\x1f.kinfer.proto.JointVelocityUnit\x12\x36\n\rposition_unit\x18\x04 \x01(\x0e\x32\x1f.kinfer.proto.JointPositionUnit"\x97\x02\n\x11JointCommandValue\x12\x12\n\njoint_name\x18\x01 \x01(\t\x12\x0e\n\x06torque\x18\x02 \x01(\x02\x12\x10\n\x08velocity\x18\x03 \x01(\x02\x12\x10\n\x08position\x18\x04 \x01(\x02\x12\n\n\x02kp\x18\x05 \x01(\x02\x12\n\n\x02kd\x18\x06 \x01(\x02\x12\x32\n\x0btorque_unit\x18\x07 \x01(\x0e\x32\x1d.kinfer.proto.JointTorqueUnit\x12\x36\n\rvelocity_unit\x18\x08 \x01(\x0e\x32\x1f.kinfer.proto.JointVelocityUnit\x12\x36\n\rposition_unit\x18\t \x01(\x0e\x32\x1f.kinfer.proto.JointPositionUnit"E\n\x12JointCommandsValue\x12/\n\x06values\x18\x01 \x03(\x0b\x32\x1f.kinfer.proto.JointCommandValue"D\n\x11\x43\x61meraFrameSchema\x12\r\n\x05width\x18\x01 \x01(\x05\x12\x0e\n\x06height\x18\x02 \x01(\x05\x12\x10\n\x08\x63hannels\x18\x03 \x01(\x05" \n\x10\x43\x61meraFrameValue\x12\x0c\n\x04\x64\x61ta\x18\x01 \x01(\x0c"]\n\x10\x41udioFrameSchema\x12\x10\n\x08\x63hannels\x18\x01 \x01(\x05\x12\x13\n\x0bsample_rate\x18\x02 \x01(\x05\x12"\n\x05\x64type\x18\x03 \x01(\x0e\x32\x13.kinfer.proto.DType"\x1f\n\x0f\x41udioFrameValue\x12\x0c\n\x04\x64\x61ta\x18\x01 \x01(\x0c"8\n\x15ImuAccelerometerValue\x12\t\n\x01x\x18\x01 \x01(\x02\x12\t\n\x01y\x18\x02 \x01(\x02\x12\t\n\x01z\x18\x03 \x01(\x02"4\n\x11ImuGyroscopeValue\x12\t\n\x01x\x18\x01 \x01(\x02\x12\t\n\x01y\x18\x02 \x01(\x02\x12\t\n\x01z\x18\x03 \x01(\x02"7\n\x14ImuMagnetometerValue\x12\t\n\x01x\x18\x01 \x01(\x02\x12\t\n\x01y\x18\x02 \x01(\x02\x12\t\n\x01z\x18\x03 \x01(\x02"W\n\tImuSchema\x12\x19\n\x11use_accelerometer\x18\x01 \x01(\x08\x12\x15\n\ruse_gyroscope\x18\x02 \x01(\x08\x12\x18\n\x10use_magnetometer\x18\x03 \x01(\x08"\xc3\x01\n\x08ImuValue\x12@\n\x13linear_acceleration\x18\x01 \x01(\x0b\x32#.kinfer.proto.ImuAccelerometerValue\x12\x39\n\x10\x61ngular_velocity\x18\x02 \x01(\x0b\x32\x1f.kinfer.proto.ImuGyroscopeValue\x12:\n\x0emagnetic_field\x18\x03 \x01(\x0b\x32".kinfer.proto.ImuMagnetometerValue"=\n\x0fTimestampSchema\x12\x15\n\rstart_seconds\x18\x01 \x01(\x03\x12\x13\n\x0bstart_nanos\x18\x02 \x01(\x05"0\n\x0eTimestampValue\x12\x0f\n\x07seconds\x18\x01 \x01(\x03\x12\r\n\x05nanos\x18\x02 \x01(\x05")\n\x13VectorCommandSchema\x12\x12\n\ndimensions\x18\x01 \x01(\x05"$\n\x12VectorCommandValue\x12\x0e\n\x06values\x18\x01 \x03(\x02"F\n\x11StateTensorSchema\x12\r\n\x05shape\x18\x01 \x03(\x05\x12"\n\x05\x64type\x18\x02 \x01(\x0e\x32\x13.kinfer.proto.DType" \n\x10StateTensorValue\x12\x0c\n\x04\x64\x61ta\x18\x01 \x01(\x0c"\xd4\x04\n\x05Value\x12\x12\n\nvalue_name\x18\x01 \x01(\t\x12<\n\x0fjoint_positions\x18\x02 \x01(\x0b\x32!.kinfer.proto.JointPositionsValueH\x00\x12>\n\x10joint_velocities\x18\x03 \x01(\x0b\x32".kinfer.proto.JointVelocitiesValueH\x00\x12\x38\n\rjoint_torques\x18\x04 \x01(\x0b\x32\x1f.kinfer.proto.JointTorquesValueH\x00\x12:\n\x0ejoint_commands\x18\x05 \x01(\x0b\x32 .kinfer.proto.JointCommandsValueH\x00\x12\x36\n\x0c\x63\x61mera_frame\x18\x06 \x01(\x0b\x32\x1e.kinfer.proto.CameraFrameValueH\x00\x12\x34\n\x0b\x61udio_frame\x18\x07 \x01(\x0b\x32\x1d.kinfer.proto.AudioFrameValueH\x00\x12%\n\x03imu\x18\x08 \x01(\x0b\x32\x16.kinfer.proto.ImuValueH\x00\x12\x31\n\ttimestamp\x18\t \x01(\x0b\x32\x1c.kinfer.proto.TimestampValueH\x00\x12:\n\x0evector_command\x18\n \x01(\x0b\x32 .kinfer.proto.VectorCommandValueH\x00\x12\x36\n\x0cstate_tensor\x18\x0b \x01(\x0b\x32\x1e.kinfer.proto.StateTensorValueH\x00\x42\x07\n\x05value"\xe9\x04\n\x0bValueSchema\x12\x12\n\nvalue_name\x18\x01 \x01(\t\x12=\n\x0fjoint_positions\x18\x02 \x01(\x0b\x32".kinfer.proto.JointPositionsSchemaH\x00\x12?\n\x10joint_velocities\x18\x03 \x01(\x0b\x32#.kinfer.proto.JointVelocitiesSchemaH\x00\x12\x39\n\rjoint_torques\x18\x04 \x01(\x0b\x32 .kinfer.proto.JointTorquesSchemaH\x00\x12;\n\x0ejoint_commands\x18\x05 \x01(\x0b\x32!.kinfer.proto.JointCommandsSchemaH\x00\x12\x37\n\x0c\x63\x61mera_frame\x18\x06 \x01(\x0b\x32\x1f.kinfer.proto.CameraFrameSchemaH\x00\x12\x35\n\x0b\x61udio_frame\x18\x07 \x01(\x0b\x32\x1e.kinfer.proto.AudioFrameSchemaH\x00\x12&\n\x03imu\x18\x08 \x01(\x0b\x32\x17.kinfer.proto.ImuSchemaH\x00\x12\x32\n\ttimestamp\x18\t \x01(\x0b\x32\x1d.kinfer.proto.TimestampSchemaH\x00\x12;\n\x0evector_command\x18\n \x01(\x0b\x32!.kinfer.proto.VectorCommandSchemaH\x00\x12\x37\n\x0cstate_tensor\x18\x0b \x01(\x0b\x32\x1f.kinfer.proto.StateTensorSchemaH\x00\x42\x0c\n\nvalue_type"5\n\x08IOSchema\x12)\n\x06values\x18\x01 \x03(\x0b\x32\x19.kinfer.proto.ValueSchema")\n\x02IO\x12#\n\x06values\x18\x01 \x03(\x0b\x32\x13.kinfer.proto.Value"j\n\x0bModelSchema\x12,\n\x0cinput_schema\x18\x01 \x01(\x0b\x32\x16.kinfer.proto.IOSchema\x12-\n\routput_schema\x18\x02 \x01(\x0b\x32\x16.kinfer.proto.IOSchema*\x88\x01\n\x05\x44Type\x12\x07\n\x03\x46P8\x10\x00\x12\x08\n\x04\x46P16\x10\x01\x12\x08\n\x04\x46P32\x10\x02\x12\x08\n\x04\x46P64\x10\x03\x12\x08\n\x04INT8\x10\x04\x12\t\n\x05INT16\x10\x05\x12\t\n\x05INT32\x10\x06\x12\t\n\x05INT64\x10\x07\x12\t\n\x05UINT8\x10\x08\x12\n\n\x06UINT16\x10\t\x12\n\n\x06UINT32\x10\n\x12\n\n\x06UINT64\x10\x0b*-\n\x11JointPositionUnit\x12\x0b\n\x07\x44\x45GREES\x10\x00\x12\x0b\n\x07RADIANS\x10\x01*C\n\x11JointVelocityUnit\x12\x16\n\x12\x44\x45GREES_PER_SECOND\x10\x00\x12\x16\n\x12RADIANS_PER_SECOND\x10\x01*$\n\x0fJointTorqueUnit\x12\x11\n\rNEWTON_METERS\x10\x00\x62\x06proto3'
24
- )
25
-
26
- _globals = globals()
27
- _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
28
- _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, "kinfer.proto.kinfer_pb2", _globals)
29
- if not _descriptor._USE_C_DESCRIPTORS:
30
- DESCRIPTOR._loaded_options = None
31
- _globals["_DTYPE"]._serialized_start = 3816
32
- _globals["_DTYPE"]._serialized_end = 3952
33
- _globals["_JOINTPOSITIONUNIT"]._serialized_start = 3954
34
- _globals["_JOINTPOSITIONUNIT"]._serialized_end = 3999
35
- _globals["_JOINTVELOCITYUNIT"]._serialized_start = 4001
36
- _globals["_JOINTVELOCITYUNIT"]._serialized_end = 4068
37
- _globals["_JOINTTORQUEUNIT"]._serialized_start = 4070
38
- _globals["_JOINTTORQUEUNIT"]._serialized_end = 4106
39
- _globals["_JOINTPOSITIONVALUE"]._serialized_start = 43
40
- _globals["_JOINTPOSITIONVALUE"]._serialized_end = 145
41
- _globals["_JOINTPOSITIONSSCHEMA"]._serialized_start = 147
42
- _globals["_JOINTPOSITIONSSCHEMA"]._serialized_end = 237
43
- _globals["_JOINTPOSITIONSVALUE"]._serialized_start = 239
44
- _globals["_JOINTPOSITIONSVALUE"]._serialized_end = 310
45
- _globals["_JOINTVELOCITYVALUE"]._serialized_start = 312
46
- _globals["_JOINTVELOCITYVALUE"]._serialized_end = 414
47
- _globals["_JOINTVELOCITIESSCHEMA"]._serialized_start = 416
48
- _globals["_JOINTVELOCITIESSCHEMA"]._serialized_end = 507
49
- _globals["_JOINTVELOCITIESVALUE"]._serialized_start = 509
50
- _globals["_JOINTVELOCITIESVALUE"]._serialized_end = 581
51
- _globals["_JOINTTORQUEVALUE"]._serialized_start = 583
52
- _globals["_JOINTTORQUEVALUE"]._serialized_end = 681
53
- _globals["_JOINTTORQUESSCHEMA"]._serialized_start = 683
54
- _globals["_JOINTTORQUESSCHEMA"]._serialized_end = 769
55
- _globals["_JOINTTORQUESVALUE"]._serialized_start = 771
56
- _globals["_JOINTTORQUESVALUE"]._serialized_end = 838
57
- _globals["_JOINTCOMMANDSSCHEMA"]._serialized_start = 841
58
- _globals["_JOINTCOMMANDSSCHEMA"]._serialized_end = 1047
59
- _globals["_JOINTCOMMANDVALUE"]._serialized_start = 1050
60
- _globals["_JOINTCOMMANDVALUE"]._serialized_end = 1329
61
- _globals["_JOINTCOMMANDSVALUE"]._serialized_start = 1331
62
- _globals["_JOINTCOMMANDSVALUE"]._serialized_end = 1400
63
- _globals["_CAMERAFRAMESCHEMA"]._serialized_start = 1402
64
- _globals["_CAMERAFRAMESCHEMA"]._serialized_end = 1470
65
- _globals["_CAMERAFRAMEVALUE"]._serialized_start = 1472
66
- _globals["_CAMERAFRAMEVALUE"]._serialized_end = 1504
67
- _globals["_AUDIOFRAMESCHEMA"]._serialized_start = 1506
68
- _globals["_AUDIOFRAMESCHEMA"]._serialized_end = 1599
69
- _globals["_AUDIOFRAMEVALUE"]._serialized_start = 1601
70
- _globals["_AUDIOFRAMEVALUE"]._serialized_end = 1632
71
- _globals["_IMUACCELEROMETERVALUE"]._serialized_start = 1634
72
- _globals["_IMUACCELEROMETERVALUE"]._serialized_end = 1690
73
- _globals["_IMUGYROSCOPEVALUE"]._serialized_start = 1692
74
- _globals["_IMUGYROSCOPEVALUE"]._serialized_end = 1744
75
- _globals["_IMUMAGNETOMETERVALUE"]._serialized_start = 1746
76
- _globals["_IMUMAGNETOMETERVALUE"]._serialized_end = 1801
77
- _globals["_IMUSCHEMA"]._serialized_start = 1803
78
- _globals["_IMUSCHEMA"]._serialized_end = 1890
79
- _globals["_IMUVALUE"]._serialized_start = 1893
80
- _globals["_IMUVALUE"]._serialized_end = 2088
81
- _globals["_TIMESTAMPSCHEMA"]._serialized_start = 2090
82
- _globals["_TIMESTAMPSCHEMA"]._serialized_end = 2151
83
- _globals["_TIMESTAMPVALUE"]._serialized_start = 2153
84
- _globals["_TIMESTAMPVALUE"]._serialized_end = 2201
85
- _globals["_VECTORCOMMANDSCHEMA"]._serialized_start = 2203
86
- _globals["_VECTORCOMMANDSCHEMA"]._serialized_end = 2244
87
- _globals["_VECTORCOMMANDVALUE"]._serialized_start = 2246
88
- _globals["_VECTORCOMMANDVALUE"]._serialized_end = 2282
89
- _globals["_STATETENSORSCHEMA"]._serialized_start = 2284
90
- _globals["_STATETENSORSCHEMA"]._serialized_end = 2354
91
- _globals["_STATETENSORVALUE"]._serialized_start = 2356
92
- _globals["_STATETENSORVALUE"]._serialized_end = 2388
93
- _globals["_VALUE"]._serialized_start = 2391
94
- _globals["_VALUE"]._serialized_end = 2987
95
- _globals["_VALUESCHEMA"]._serialized_start = 2990
96
- _globals["_VALUESCHEMA"]._serialized_end = 3607
97
- _globals["_IOSCHEMA"]._serialized_start = 3609
98
- _globals["_IOSCHEMA"]._serialized_end = 3662
99
- _globals["_IO"]._serialized_start = 3664
100
- _globals["_IO"]._serialized_end = 3705
101
- _globals["_MODELSCHEMA"]._serialized_start = 3707
102
- _globals["_MODELSCHEMA"]._serialized_end = 3813
103
- # @@protoc_insertion_point(module_scope)