Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installation fails #35

Open
snth768 opened this issue Jan 30, 2025 · 0 comments
Open

Installation fails #35

snth768 opened this issue Jan 30, 2025 · 0 comments

Comments

@snth768
Copy link

snth768 commented Jan 30, 2025

On ubuntu 24.04, I tried to install the requirements and run the notebook on python 3.7, 3.9 and 3.10. In each case, it does not work. After installing requirements.txt, I am still missing matplotlib, colour and chalk. When I also install these, I get the error

{
	"name": "NameError",
	"message": "name 'vstrut' is not defined",
	"stack": "---------------------------------------------------------------------------
NameError                                 Traceback (most recent call last)
Cell In[2], line 5
      2     \"Use this function to replace a for-loop.\"
      3     return torch.tensor(range(i))
----> 5 draw_examples(\"arange\", [{\"\" : arange(i)} for i in [5, 3, 9]])

File ~/Documents/tensor_questions/Tensor-Puzzles/lib.py:83, in draw_examples(name, examples)
     78 def draw_examples(name, examples):
     79     data = {\"name\":name,
     80                   \"vals\" :[{k: [v.tolist()] if len(v.shape) == 1 else v.tolist() 
     81                         for k, v in example.items()}
     82                         for example in examples ] }
---> 83     return draw_example(data)

File ~/Documents/tensor_questions/Tensor-Puzzles/lib.py:57, in draw_example(data)
     55 cols = []
     56 for k in keys:
---> 57     mat = [(vstrut(0.5) / text(k, 0.5).fill_color(Color(\"black\")).line_width(0.0) / vstrut(0.5))]         
     58     for ex in data[\"vals\"]:
     59         v2 = ex[k]           

NameError: name 'vstrut' is not defined"
}

I guess because it should have been imported from chalk with the star imports. Could the correct version of chalk be added to the requirements.txt?

Also, does anyone know why I have this problem but no one else in the issues has mentioned it?

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant