Comments (7)
Having nim evaluate the code is an interesting idea, but the main reason I didn't implement that is graphs, as far as I know none of the plotting libraries work in the vm (ok, technically nim-plotly might work), and similarly numerical libraries.
Since that was my main use for this, I ended up with compiled nim. It should be relatively easy, just a matter of changing nim c
to nim e
.
Other option for faster cell execution is using https://bellard.org/tcc/ as the C compiler (this should work with most of nim) or feeding single lines to nim secret
. I'll hopefully have time soon to update zmq
code to work with the latest version, so maybe I'll give some of this a try.
Of course, any help is appreciated! And hearing from users is always very helpful to find bugs that just don't appear on my system.
from jupyternim.
What about giving the possibility to use Nimscript instead of compiled Nim? Even if still limited it can handle almost all the standard libraries and would be great for people just learning and experimenting Nim, the cells would execute way faster.
P.S. I can help with the less programming-intensive part (for sure with the Logo).
from jupyternim.
Indeed Arraymancer and other libraries don't work on Nimscript, but it would be a great way for newbies to learn the basis of the language and of the standard library without having to wait 5-30 seconds for each cell. It would be nice to just have the option as alternative to the default compilation.
I would also report a issue I found: I receive the error "Kernel is dead" whenever I try to pass the flag #>flags --c:tcc
.
Last but not least, I made a logo. Tell me if you like the idea or if you want me to modify something. However, it's made only for dark websites. It's thought for Github on dark mode, so it has white elements and transparent background, but I can easily made other versions once it is approved 🙂
from jupyternim.
Hey! Sorry for not getting back to you, thanks for reporting a bug, I'll look into it.
About the logo, nice work! What about using the crown instead of the orange parts? So it would just be Jupyternim superimposed on the crown, with the moons orbiting around it. I think that would look cleaner?
from jupyternim.
What about using inim? They are better at interactive stuff already.
nim>1
1 == type int
nim> 2
2 == type int
nim>
It has "hot reload" too. It compiles the imported file again on every REPL loop.
from jupyternim.
Hey! Thanks for the comment. Jupyternim and inim work the same under the hood, or at least they did last time I checked. Neither implements hcl as it's still too buggy on the nim side.
Switching to use inim doesn't seem to offer much benefit, compiling a cell is already slow, and switching from direct jupyter>nim>result to jupyter>inim>nim>result would probably make it worse.
I'll see if I can provide a way to select the compiler, that way you could just run your code with nim or inim by changing a flag.
The convenience of seeing value and type of the value is something we could probably add, although I'd prefer the type in the tooling part (eg with nim suggest) instead of the reply
from jupyternim.
inim's support for directly showing the expression value is buggy. A multiline expression will fail:
import sugar, sequtils
collect(newSeq):
for i in 0..3:
i
from jupyternim.
Related Issues (13)
- Error \u allowed in character literal
- zmq.nim(737, 18) Error: cannot instantiate: 'T'
- build failed on Windows 10 HOT 10
- Adding an option to compile a cell/the whole kernel to c/cpp? HOT 4
- cant install `jupyternim` on nim 1.4.8 HOT 3
- zmq.dll problem HOT 3
- Jupyternim fails to install on macOS HOT 13
- Why requires zmq < 1.3.0 ? HOT 2
- example-notebook.ipynb missing imports
- INim => JNim ? inim already taken by https://github.com/AndreiRegiani/INim HOT 5
- Error installing jupyternim from source on macOS HOT 2
- Need to update for Nim 0.20
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jupyternim.