Jupyter notebook markdown tips

Tip No. 1- Tip No. 100000: play around and click every button. If you are willing to do this continuously, you will be better than half of the programmers soon, and probably can answer most of the questions in Stackoverflow related to Jupyter Notebook markdown. Go ahead, it won’t break. The worst it could happen is restart. If you have to undo, hit Esc, then ctrl + z.

More

python numpy basics | 基础 python numpy 1

Tonight our class played together numpy basics and math.  We put together a numpy basics notebook:
https://nbviewer.jupyter.org/github/magicmathmandarin/PythonBasics/blob/master/numpy_basics1.ipynb#back-to-top

Programming by trial and error is a great way for kids to learn not only programming but also math. — this should play a bigger and bigger role in children’s day to day learning.  玩编程也帮助学习算术。

Somehow I have a feeling that learning long division in this day and age is wrong.  在这个时代还学长除法那就不对了。

Go ahead and tinker with the code in the notebook. Nothing will break, we promise 🙂

tensorflow upgrade and testing | tensorflow 升级和测试

It has been over a year since I last used tensorflow. Not only library versions have changed, but also the syntax. My old jupyter notebook was throwing errors all over the place this morning. It is time to update everything.

For tensorflow, I am using Python 3.6.3 (I used to use Python 3.5), and numpy 1.16.1. TensorFlow has a few dependencies. numpy is one of them. Note the mnist dataset has 70,000 images.

python -c ‘import tensorflow as tf; print(tf.__version__)

More

An great collection of Python notebooks | Python 笔记本集

Here is a really great collection of Python notebooks with lots and lots of links.  We start with some appetizers:

But there are so many and so much more!! Okay, I am just going to copy (fork) most of this page:

Mathematics

  • Linear algebra with Cython. A tutorial that styles the notebook differently to show that you can produce high-quality typography online with the Notebook. By Carl Vogel.
  • More

API

Yes, this is still a Magic Math Mandarin blog–but to have tomorrow’s skills means a lot more than just knowing basic math.
API = plugin

This post is a quick note (updates are in progress).

Site that documents most APIs
https://www.programmableweb.com/
More

hash function/ cryptography/ digital signiture

Hash function (散列函數):
Yes, this is still a Magic Math Mandarin blog–but to have tomorrow’s skills means a lot more than just knowing basic math.
A hash function maps arbitrary string of data fix length of bits.

The simplest (a bad one) is to use the ASCii representation of alphabet, sum up the numbers and take mod.   This creates a problem as “cat”, “act” and “tca” are going to be mapped to the same hash.  This problem is called “hash collision” 碰撞.

More

A CS lecture 马克十几年前教的课

It is amazing how much one can learn from this old video, recorded 2 years after Mark Zuckerburg left Harvard. Here is what I remember after listening 5 times:

1. Don’t follow what the big guys are doing. There is so much you can do on your own with technology (find your own problem and get to it)
More

Git and Github

Q: What is git?
A: It is a digit without di 🙂   Git is currently the best (commonly used) tool for version control 目前最好的版本控制系统.
Motivation

Github can be used for your own code version control by mirroring the code of a folder in your own computer. It enables version control and has workflow capabilities.   Note: if you just want syncing, use Dropbox; git and Github can be a bit confusing.
More