Skip to content

Commit

Permalink
Add the dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
Orif Milod committed Mar 15, 2024
1 parent c7bde98 commit c38c9f5
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 2 deletions.
2 changes: 1 addition & 1 deletion example/language_model/language-model.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import torch.nn.functional as F
import matplotlib.pyplot as plt

# How much tokens to keep as context when making the prediction for the next one
# Number of tokens to keep as context when making the prediction for the next one
CONTEXT_SIZE = 3
# Size of the vector to represent a single token
EMBEDDING_SIZE = 10
Expand Down
1 change: 0 additions & 1 deletion gigatorch/nn.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ def __call__(self, x):
def calc_loss(self, ys, y_pred):
# Convertin y_pred to probabilities
prob = [self.prob_fn(i, y_pred) for i in y_pred]
print("Prob", prob)
loss = sum(self.loss_fn(ys, y_pred), Tensor(0))
loss.backprop()
return loss.data
Expand Down
34 changes: 34 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,21 +1,55 @@
appnope==0.1.4
asttokens==2.4.1
black==24.2.0
click==8.1.7
comm==0.2.2
contourpy==1.2.0
cycler==0.12.1
debugpy==1.8.1
decorator==5.1.1
executing==2.0.1
filelock==3.13.1
fonttools==4.49.0
fsspec==2024.2.0
iniconfig==2.0.0
ipykernel==6.29.3
ipython==8.22.2
jedi==0.19.1
Jinja2==3.1.3
jupyter_client==8.6.1
jupyter_core==5.7.2
kiwisolver==1.4.5
MarkupSafe==2.1.5
matplotlib==3.8.3
matplotlib-inline==0.1.6
mpmath==1.3.0
mypy-extensions==1.0.0
nest-asyncio==1.6.0
networkx==3.2.1
numpy==1.26.4
packaging==23.2
parso==0.8.3
pathspec==0.12.1
pexpect==4.9.0
pillow==10.2.0
platformdirs==4.2.0
pluggy==1.4.0
prompt-toolkit==3.0.43
psutil==5.9.8
ptyprocess==0.7.0
pure-eval==0.2.2
Pygments==2.17.2
pyparsing==3.1.2
pytest==8.0.2
python-dateutil==2.9.0.post0
pyzmq==25.1.2
setuptools-black==0.1.5
six==1.16.0
stack-data==0.6.3
sympy==1.12
torch==2.2.1
torchvision==0.17.1
tornado==6.4
traitlets==5.14.2
typing_extensions==4.10.0
wcwidth==0.2.13

0 comments on commit c38c9f5

Please sign in to comment.