oikan 0.0.1__py3-none-any.whl → 0.0.1.1__py3-none-any.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.
oikan/trainer.py CHANGED
@@ -16,9 +16,8 @@ def train(model, train_loader, epochs=100, lr=0.01):
16
16
 
17
17
  for epoch in range(epochs):
18
18
  optimizer.step(closure)
19
- if epoch % 10 == 0:
20
- print(f"Epoch {epoch+1}/{epochs}")
21
-
19
+ print(f"Epoch {epoch+1}/{epochs}")
20
+
22
21
  # Classification training
23
22
  def train_classification(model, train_loader, epochs=100, lr=0.01):
24
23
  criterion = nn.CrossEntropyLoss()
@@ -30,5 +29,4 @@ def train_classification(model, train_loader, epochs=100, lr=0.01):
30
29
  loss = criterion(outputs, train_loader[1])
31
30
  loss.backward()
32
31
  optimizer.step()
33
- if (epoch + 1) % 10 == 0:
34
- print(f"Epoch {epoch+1}/{epochs}, Loss: {loss.item()}")
32
+ print(f"Epoch {epoch+1}/{epochs}, Loss: {loss.item()}")
@@ -0,0 +1,65 @@
1
+ Metadata-Version: 2.2
2
+ Name: oikan
3
+ Version: 0.0.1.1
4
+ Summary: OIKAN: Optimized Interpretable Kolmogorov-Arnold Networks
5
+ Author: Arman Zhalgasbayev
6
+ License: MIT
7
+ Classifier: Programming Language :: Python :: 3
8
+ Classifier: License :: OSI Approved :: MIT License
9
+ Classifier: Operating System :: OS Independent
10
+ Requires-Python: >=3.7
11
+ Description-Content-Type: text/markdown
12
+ Requires-Dist: torch
13
+ Requires-Dist: numpy
14
+ Requires-Dist: sympy
15
+ Requires-Dist: scipy
16
+ Requires-Dist: matplotlib
17
+
18
+ # OIKAN Library
19
+
20
+ [![PyPI version](https://badge.fury.io/py/oikan.svg)](https://badge.fury.io/py/oikan)
21
+ [![PyPI downloads](https://img.shields.io/pypi/dm/oikan.svg)](https://pypistats.org/packages/oikan)
22
+
23
+ OIKAN (Optimized Implementation of Kolmogorov-Arnold Networks) is a PyTorch-based library for creating interpretable neural networks. It implements the KAN architecture to provide both accurate predictions and interpretable results.
24
+
25
+ ## Key Features
26
+
27
+ - EfficientKAN layer implementation
28
+ - Built-in visualization tools
29
+ - Support for both regression and classification tasks
30
+ - Symbolic formula extraction
31
+ - Easy-to-use training interface
32
+
33
+ ## Installation
34
+
35
+ ```bash
36
+ git clone https://github.com/silvermete0r/OIKAN.git
37
+ cd OIKAN
38
+ pip install -e . # Install in development mode
39
+ ```
40
+
41
+ ## Quick Start
42
+
43
+ ### Regression Example
44
+ ```python
45
+ from oikan.model import OIKAN
46
+ from oikan.trainer import train
47
+
48
+ # Create and train model
49
+ model = OIKAN(input_dim=2, output_dim=1)
50
+ train(model, train_loader)
51
+
52
+ # Extract interpretable formula
53
+ formula = extract_symbolic_formula_regression(model, X)
54
+ ```
55
+
56
+ ### Classification Example
57
+ ```python
58
+ model = OIKAN(input_dim=2, output_dim=2)
59
+ train_classification(model, train_loader)
60
+ visualize_classification(model, X, y)
61
+ ```
62
+
63
+ ## Contributing
64
+
65
+ Contributions are welcome! Please feel free to submit a Pull Request.
@@ -0,0 +1,9 @@
1
+ oikan/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
+ oikan/model.py,sha256=LTWlXTlmeTwNe70Q7vjGOG6MUukCuWoHryvHB_yPzjc,1035
3
+ oikan/symbolic.py,sha256=QjNGWU6LpPzZ35b-WYmSEYPM5FH9tKMS5pKgCujFd64,1431
4
+ oikan/trainer.py,sha256=FmZ2TtcPiaam4ip0AzpzL6BXzDtsouh34GjhIxl0btw,1033
5
+ oikan/visualize.py,sha256=J58pbWYaqV5vWkkRNUem0Jse5gHjQ-rRDKQDPIJouW0,729
6
+ oikan-0.0.1.1.dist-info/METADATA,sha256=F77-yv451wCW6hzQsb9nJPHfI2YBDLFyK6S2mSn69JY,1872
7
+ oikan-0.0.1.1.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
8
+ oikan-0.0.1.1.dist-info/top_level.txt,sha256=XwnwKwTJddZwIvtrUsAz-l-58BJRj6HjAGWrfYi_3QY,6
9
+ oikan-0.0.1.1.dist-info/RECORD,,
@@ -1,10 +0,0 @@
1
- Metadata-Version: 2.2
2
- Name: oikan
3
- Version: 0.0.1
4
- Summary: OIKAN: Optimized Interpretable Kolmogorov-Arnold Networks
5
- Author: Arman Zhalgasbayev
6
- Requires-Dist: torch
7
- Requires-Dist: numpy
8
- Requires-Dist: sympy
9
- Requires-Dist: scipy
10
- Requires-Dist: matplotlib
@@ -1,9 +0,0 @@
1
- oikan/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
- oikan/model.py,sha256=LTWlXTlmeTwNe70Q7vjGOG6MUukCuWoHryvHB_yPzjc,1035
3
- oikan/symbolic.py,sha256=QjNGWU6LpPzZ35b-WYmSEYPM5FH9tKMS5pKgCujFd64,1431
4
- oikan/trainer.py,sha256=4CWcBCRLhMXEtnEevVt2qe3lNXzoS0HUH6weHE2GwUw,1111
5
- oikan/visualize.py,sha256=J58pbWYaqV5vWkkRNUem0Jse5gHjQ-rRDKQDPIJouW0,729
6
- oikan-0.0.1.dist-info/METADATA,sha256=zNk3LtgHe5TIYBy49l4t5tYDgQdUOHu0Jh1a56bTym4,263
7
- oikan-0.0.1.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
8
- oikan-0.0.1.dist-info/top_level.txt,sha256=XwnwKwTJddZwIvtrUsAz-l-58BJRj6HjAGWrfYi_3QY,6
9
- oikan-0.0.1.dist-info/RECORD,,
File without changes