Giter Club home page Giter Club logo

fall-in-love-with-julia's Introduction

image

fall-in-love-with-julia

Binder

An introductory 101 series to get to know the power of Julialang.

Author: Stephan Sahm, Julia User Group Munich.

To open a specific notebook, go to it in github and press the "launch binder" button. screenshot

Why Julia?

Why was Julia created? Definitely read this now impressively old post by Julia founders by Jeff Bezanson, Stefan Karpinski, Viral B. Shah, and Alan Edelman https://julialang.org/blog/2012/02/why-we-created-julia/.

Here my favourite passage

We want the speed of C with the dynamism of Ruby. We want a language that's homoiconic, with true macros like Lisp, but with obvious, familiar mathematical notation like Matlab. We want something as usable for general programming as Python, as easy for statistics as R, as natural for string processing as Perl, as powerful for linear algebra as Matlab, as good at gluing programs together as the shell. Something that is dirt simple to learn, yet keeps the most serious hackers happy. We want it interactive and we want it compiled.

Why this needs to be an extra language? Why cannot Python be made that fast for instance? Checkout the official compact answer to this in the julia manual F&Q https://docs.julialang.org/en/v1/manual/faq/#Why-don't-you-compile-Matlab/Python/R/%E2%80%A6-code-to-Julia?-1

Here my favourite passage

Julia's advantage is that good performance is not limited to a small subset of “built-in” types and operations, and one can write high-level type-generic code that works on arbitrary user-defined types while remaining fast and memory-efficient. Types in languages like Python simply don't provide enough information to the compiler for similar capabilities, so as soon as you used those languages as a Julia front-end you would be stuck.

Local installation

If Binder does not work for you, you can install the package locally. There are two options, using docker, or using plain julia.

Docker (recommended)

This process is identical to how mybinder.org is actually doing it. Hence you will get the very same environment.

  1. Install docker

  2. Install repo2docker by running in a terminal (bash)

    python3 -m pip install --user jupyter-repo2docker

    If you do not have python, consider installing it via Anaconda.

  3. Execute repo2docker on this repository. It will take several 10 minutes to build everything. Again in a terminal (bash):

    jupyter-repo2docker https://github.com/jolin-io/fall-in-love-with-julia

    Usually, a browser is opened automatically for you, but if not, an url is also printed at the very end of the command output. Copy that one to your browser and you are ready to go.

No docker

This process is installing dependencies tracked by Julia, which will suffice for 98% of the material here.

  1. Download and install Julia from https://julialang.org/downloads/

  2. Instantiate the fall-in-love-with-julia package. Run the following in a terminal (bash/zsh, for Windows use WSL)

    ProjectFolder="$HOME/JuliaProjects"
    mkdir -p "$ProjectFolder"
    cd "$ProjectFolder"
    
    git clone https://github.com/jolin-io/fall-in-love-with-julia
    julia --project="$ProjectFolder/fall-in-love-with-julia" --eval 'import Pkg; Pkg.instantiate(); Pkg.add("IJulia")'
  3. Run jupyter

    Either use your favorite jupyter installation or run in a terminal (bash/zsh, for Windows use WSL)

    ProjectFolder="$HOME/JuliaProjects"
    julia --project="$ProjectFolder/fall-in-love-with-julia" --eval 'import IJulia; notebook()'

In case a specific example (e.g. the Streaming Kaggle example) does not work, you may need to install extra packages similar to those described in apt.txt or execute further steps on the commandline similar to those described in postBuild.

fall-in-love-with-julia's People

Contributors

schlichtanders avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fall-in-love-with-julia's Issues

Clearify the install instructions

The first line(s) of your installation instructions do lack any info, of which environment you expect us to run them in:

ProjectFolder="$HOME/JuliaProjects"

Is this something I am supposed to add in my command line?
The Julia document?

Considering this is an introduction course, I hope people check the documented from the perspective of a newbie.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.