hyper-connections 0.1.4__tar.gz → 0.1.5__tar.gz
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.
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/PKG-INFO +1 -1
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/hyper_connections/hyper_connections_with_multi_input_streams.py +2 -2
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/pyproject.toml +1 -1
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/.github/workflows/python-publish.yml +0 -0
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/.github/workflows/test.yml +0 -0
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/.gitignore +0 -0
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/LICENSE +0 -0
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/README.md +0 -0
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/hyper-connections.png +0 -0
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/hyper_connections/__init__.py +0 -0
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/hyper_connections/hyper_connections.py +0 -0
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/hyper_connections/hyper_connections_with_multi_branch_inputs.py +0 -0
- {hyper_connections-0.1.4 → hyper_connections-0.1.5}/tests/test_hyper_connections.py +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
from __future__ import annotations
|
|
2
|
-
from typing import Callable
|
|
2
|
+
from typing import Callable, Union
|
|
3
3
|
|
|
4
4
|
from functools import partial
|
|
5
5
|
from random import randrange
|
|
@@ -142,7 +142,7 @@ class Residual(Module):
|
|
|
142
142
|
|
|
143
143
|
# hyper connection with multiple input streams
|
|
144
144
|
|
|
145
|
-
InputPathType = int
|
|
145
|
+
InputPathType = Union[int, str] # the path to the second residual stream, where `int` points to *args[`int`] and `str` points to **kwargs[`str`] - `int` needs to be > 0, as 0 is the default input residual stream
|
|
146
146
|
|
|
147
147
|
class HyperConnections(Module):
|
|
148
148
|
def __init__(
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|