Phil Trelford's Array
POKE 36879, 255

Machine Learning Hands On Session

June 13, 2013 23:43 by phil

Last night the F#unctional Londoners Meetup put on a Hands On Machine Learning session at Skills Matter in London. It was a really well attended event, so much so that we had to put a cap on the number of attendees when we reached 70 registrations. The material was recycled from a well received session by Mathias Brandewinder at the San Francisco Bay Area F# User Group in May.

I find F# a very good fit for Machine Learning, in fact my first use of F# was for the player matchmaking on Halo 3.

The goal of the session was to create a digit recognizer using Kaggle’s competition data set.


The first part of the session was to parse and transform the provided CSV files:

let path = @"c:\Digits\digitssample.csv"
let lines = File.ReadAllLines(path)
lines |> Array.map (fun line -> line.Split(','))

Then to implement the K-nearest neighbours algorithm to classify digits. KNN is the first algorithm explained in Manning’s Machine Learning in Action book.

pharrington_cover150

We used a guided script in the session that takes you through the problem in small manageable tasks, each one introducing the necessary F# language contructs required, which you could work through at home too.

Thanks for all the kind feedback:

  1. Finn NeuikFinn Neuik@finnneuik

    great evening at #fsharp UG courtesy of #kaggle, @skillsmatter and @ptrelford : I do like a bit of machine learning!

  2. James CrowleyJames Crowley@JamesCrowley

    Great evening learning some F# and machine learning with the help of @ptrelford @skillsmatter - thanks Phil!

  3. Andy BrackleyAndy Brackley@andybrackley

    Thanks @ptrelford for a great session on machine learning in f#. Excellent content and presentation

  4. Chris AustinChris Austin@cja117

    @ptrelford thanks for a great #fsharp workshop at #SkillsMatter in London.


If you’re interested in learning more check out:the Machine Learning with F# page on the F# Software Foundation site which includes plenty more tutorials.


Tags:
Categories: F# | .Net | Twitter
Actions: E-mail | Permalink | Comments (3) | Comment RSSRSS comment feed

Progressive F# Tutorials London 2012

November 4, 2012 16:03 by phil

First things first, a big thanks to the team at Skills Matter particularly Wendy and Anaïs for making this event happen.

progfsharp-670x180px

This year the tutorials were held over 2 days in the atmospheric Crypt in Clerkenwell:

Progressive F# PanelProgressive F# Panel Progressive F# PanelSimon Cousins & Tomas Petrick

Expect a return next year in London and New York.

Day 1

 

Practical Functional-first Programming with F#

dsyme

Friends don't let friends use null


An outstanding keynote from Don which built on the talk he gave at the Progressive .Net Tutorials earlier in the year, stacked full of nuggets. On measuring if you have a correctness problem in your code base Don suggests counting the occurrences of NullReferenceException in your bug database.

Don also demonstrated F# 3.0’s Type Provider feature, including a very interesting Hive type provider for Hadoop written by Matt Moloney.

 

Programming with the stars!

tomaspetricek

I generally avoid 'function' when showing the language to newcomers. Not a problem at #progfsharp :-)

nrolland

i'm going to the Progressive F# Tutorials at #SkillsMatter Nov 1-2 intense coding with the greats of #Fsharp! http://bit.ly/SMprogFsharp


To demonstrate how to tackle problems with F#, Tomas & Nicolas neatly solved the Reversi kata live on stage. They started by transforming a board to a 2D array and then searched the array for legal moves.

 

F# Koans

chrismarinos

Ready for some koans fun at #progfsharp!


The F# Koans are a simple, fun, and interactive way to learn the F# language through testing. You can run them from VS2010 or VS2012. My 10yo really enjoyed working his way through them.

 

Processing concurrent time-series data

simontcousins

See you at the Progressive F# Tutorials 2012 http://t.co/y1FG9GGe


tomaspetricek

Not to miss #fsharp events! Tutorials at #skillsmatter in 2 weeks & Type-providers and financial tutorial at #techmesh tomasp.net/blog/…


Simon worked through some of the techniques he has used while developing solution in F# at E.ON Energy Trading for the last 4 years. There was also some ASCII art

 

Expert Panel Discussion

nickpalladinosmartintrojerdanielegloffcolinbulrobertpijonharrop

A very lively and fun debate, covering topics from industrial use of F#, cross-platform with Mono and the JVM, to data parallelism. Jon offered that several teams at Aviva, one of the world’s largest insurers, are using F#. Martin felt that F# on the JVM would be a smash hit. Finally Nick wetted our appetite for the upcoming release of {m}brace.

 

Day 2

 

Accelerate your TDD cycle – Coding dojo with NaturalSpec and NCrunch

sforkman

yfrog.com/h4h4yzej turns out the whole "in the crypt" thing - not a joke. #progfsharp

In this session Steffen introduced TDD with F# using NaturalSpec and NCrunch.

 

Make Music in the Key of F#

robertpi

@AnaisatSM thanks for having us, it really was a lovely event! /cc@skillsmatter @wendydevolder @ptrelford

 

Robert introduced Undertone a library for creating notes in F#, part inspired by Clojure’s Overtone. With the F# Koans under his belt my 10yo was able to translate the Baa Baa Black Sheep sample to Jingle Bells :)

 

F# in the Cloud

gmstavroulakisgianntzik

In this session, George and Gian demonstrated that F# can be used to perform computations in a cloud environment, using distributed actors, Azure Hadoop and the cool F# newcomer, {m}brace.

 

Web Programming

oenotriaptrelford

James started by talking through the F# MVC project template from Daniel Mohl.

After a short tea break I demonstrated some F# 3 type providers starting with accessing Stack Overflow’s API using the F# team’s OData type provider, followed by the file system and Freebase providers which are available in FSharpx via Nuget. Finishing up with a demo of the F# team’s B-Movie Madness sample web application which I’ve deployed on Azure.

James followed on with a site built using tube passenger statistics from TfL and a CSV type provider. Finally James demonstrated WebSharper compiling F# code directly to JavaScript.

 

Community Action

Thanks for stopping by, hope to see y’all at some of the upcoming fun F# community events:


Tags:
Categories: F# | .Net | JavaScript | Clojure | Twitter
Actions: E-mail | Permalink | Comments (1) | Comment RSSRSS comment feed

Strangeloop 2012

September 26, 2012 07:38 by Phil

This year I had the privilege of attending and speaking at the Strangeloop conference in St Louis. The venues, the Union Street Marriot (a National Historic Landmark), and the Peabody Opera House were spectacular.

StLouisUnionStationHotelExterior

The range of sessions and speakers was literally mind boggling. Some of my favourites:

The breakfast hallway conversations were friendly and insightful, thanks to everyone for all the great feedback on my talk.

F# for Trading

Many people in the community use F# for Trading, and not just developers, traders too. Community matters in a language. The talk looked at some of the reasons people choose to use F# in Trading and some of the projects they have built to support their efforts, like Type Providers for Excel and the R statistical programming language.


The talk was recorded so expect a video to appear on InfoQ at some point in the future.

References

Strangeloop.zip (4.15 mb)


Tags:
Categories: .Net | BDD | C# | C++ | F# | JavaScript | Twitter
Actions: E-mail | Permalink | Comments (0) | Comment RSSRSS comment feed