Lecture 1: Introduction to Research — [📝Lecture Notebooks] [
Lecture 2: Introduction to Python — [📝Lecture Notebooks] [
Lecture 3: Introduction to NumPy — [📝Lecture Notebooks] [
Lecture 4: Introduction to pandas — [📝Lecture Notebooks] [
Lecture 5: Plotting Data — [📝Lecture Notebooks] [[
/* | |
Copy this into the console of any web page that is interactive and doesn't | |
do hard reloads. You will hear your DOM changes as different pitches of | |
audio. | |
I have found this interesting for debugging, but also fun to hear web pages | |
render like UIs do in movies. | |
*/ | |
const audioCtx = new (window.AudioContext || window.webkitAudioContext)() |
import sys | |
# choose() is the same as computing the number of combinations. Normally this is | |
# equal to: | |
# | |
# factorial(N) / (factorial(m) * factorial(N - m)) | |
# | |
# but this is very slow to run and requires a deep stack (without tail | |
# recursion). | |
# |
After installing the latest Wine release, which currently is 2.0 (I chose the development branch) on XQuartz 2.7.11, I was having problems with blurry text in both winecfg, regedit and other programs launched through Wine. After trying to enable font smoothing and font replacements (source) with only slight changes I found someone trying to solve the same issues (source), albeit compiling everything from scratch which I don't want to do. It turns out that the Retina display on my MacBook Pro was causing the issues with blurry fonts because Wine was not using the "real" resolution, only the reported "lower resolution".
To enable Retina support in Wine open the registry editor via a terminal, preferably through Wine Devel.app installed with Wine:
$ wine regedit
Then find the folder/key:
Principles of Adult Behavior
- Be patient. No matter what.
- Don’t badmouth: Assign responsibility, not blame. Say nothing of another you wouldn’t say to him.
- Never assume the motives of others are, to them, less noble than yours are to you.
- Expand your sense of the possible.
- Don’t trouble yourself with matters you truly cannot change.
- Expect no more of anyone than you can deliver yourself.
- Tolerate ambiguity.
- Laugh at yourself frequently.
### | |
### | |
### UPDATE: For Win 11, I recommend using this tool in place of this script: | |
### https://christitus.com/windows-tool/ | |
### https://github.com/ChrisTitusTech/winutil | |
### https://www.youtube.com/watch?v=6UQZ5oQg8XA | |
### iwr -useb https://christitus.com/win | iex | |
### | |
### |
# Author: Jean-Remi King <[email protected]> | |
""" | |
Illustrate how a hinge loss and a log loss functions | |
typically used in SVM and Logistic Regression | |
respectively focus on a variable number of samples. | |
For simplification purposes, we won't consider the | |
regularization or penalty (C) factors. | |
""" | |
import numpy as np | |
import matplotlib.animation as animation |