This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| The most atomic way to train and run inference for a GPT in pure, dependency-free Python. | |
| This file is the complete algorithm. | |
| Everything else is just efficiency. | |
| @karpathy | |
| """ | |
| import os # os.path.exists | |
| import math # math.log, math.exp |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (* | |
| This is a reaction to this blog post by Steve Shogren: | |
| http://deliberate-software.com/safety-rank-part-2/ | |
| *) | |
| #I @"../packages" | |
| #r @"Accord.3.0.1-alpha\lib\net45\Accord.dll" | |
| #r @"Accord.MachineLearning.3.0.1-alpha\lib\net45\Accord.MachineLearning.dll" | |
| #r @"Accord.Math.3.0.1-alpha\lib\net45\Accord.Math.dll" | |
| #r @"Accord.Statistics.3.0.1-alpha\lib\net45\Accord.Statistics.dll" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /// <reference path="../../typings/tsd.d.ts" /> | |
| /// | |
| import {PipeFactory} from 'angular2/src/change_detection/pipes/pipe'; | |
| import {async} from 'angular2/src/change_detection/change_detection'; | |
| import {NullPipeFactory, Pipe, PipeRegistry, defaultPipes} from 'angular2/change_detection'; | |
| import {bind} from 'angular2/di'; | |
| import {ObservablePipe} from 'angular2/pipes'; | |
| import * as Rx from 'rx'; | |
| export function isObservable(obs) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //========================================== | |
| // Working fully self-contained getting-started example for Suave Web Server scripting | |
| // | |
| // Note you don't need to have _anything_ installed before starting with this script. Nothing | |
| // but F# Interactive and this script. | |
| // | |
| // This script fetches the Paket.exe component which is referenced later in the script. | |
| // Initially the #r "paket.exe" reference is shown as unresolved. Once it has been | |
| // downloaded by the user (by executing the first part of the script) the reference | |
| // shows as resolved and can be used. |
- F-Words - Functional Programming Terms With More Than Four Letters - Calvin Bottoms
- Reactive Game Development For The Discerning Hipster - Bodil Stokke
- Erlang Patterns Matching Business Needs -- Torben Hoffman
- Equivalence Classes, xUnit.net, FsCheck, Property-Based Testing -- Mark Seemann
- Functional programming design patterns -- Scott Wlaschin
- Write Your Own Compiler in 24 Hours -- Phillip Trelford
People
:bowtie: |
π :smile: |
π :laughing: |
|---|---|---|
π :blush: |
π :smiley: |
:relaxed: |
π :smirk: |
π :heart_eyes: |
π :kissing_heart: |
π :kissing_closed_eyes: |
π³ :flushed: |
π :relieved: |
π :satisfied: |
π :grin: |
π :wink: |
π :stuck_out_tongue_winking_eye: |
π :stuck_out_tongue_closed_eyes: |
π :grinning: |
π :kissing: |
π :kissing_smiling_eyes: |
π :stuck_out_tongue: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # DOCKER-VERSION 0.4.8 | |
| FROM base:ubuntu-12.10 | |
| RUN apt-get -y install mono-devel autoconf pkg-config make git libtool | |
| RUN git clone https://github.com/fsharp/fsharp | |
| RUN cd fsharp && ./autogen.sh --prefix /usr && make && make install |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $scriptDir = $(Split-Path -parent $MyInvocation.MyCommand.Definition) | |
| function Install-NeededFor { | |
| param( | |
| [string] $packageName = '' | |
| ,[bool] $defaultAnswer = $true | |
| ) | |
| if ($packageName -eq '') {return $false} | |
| $yes = '6' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Mimic type classes with additional param | |
| type 'a Num = { | |
| zero: 'a | |
| add: 'a -> 'a -> 'a | |
| mult: 'a -> 'a -> 'a | |
| fromInteger: int -> 'a } | |
| let intNum = { | |
| zero = 0 |
NewerOlder