Skip to content

Instantly share code, notes, and snippets.

View danielronnkvist's full-sized avatar

Daniel Rönnkvist danielronnkvist

View GitHub Profile
@danielronnkvist
danielronnkvist / tjock.js
Created April 9, 2015 20:41
Make it fat
function makeFat(el){
el.style.fontWeight = "bold";
el.style.border = "10px solid";
if(typeof(el.childNodes) === "array"){
el.childNodes.forEach(function(elem){
makeFat(elem);
});
}
}
makeFat(document.body);
<%= link_to image_tag(image.public_thumb_url, alt: t('.view_big')), image.public_url, title: "#{album.title}<small>#{image.user.name}, MTD 2015</small>" %>
@danielronnkvist
danielronnkvist / Default.sublime-keymap
Last active August 29, 2015 14:15
Sublime text settings
[
{ "keys": ["ctrl+tab"], "command": "next_view" },
{ "keys": ["ctrl+shift+tab"], "command": "prev_view" },
{ "keys": ["ctrl+alt+o"], "command": "prompt_open_folder" },
{ "keys": ["ctrl+'"], "command": "toggle_comment", "args": { "block": false } },
{ "keys": ["ctrl+shift+'"], "command": "toggle_comment", "args": { "block": true } },
{ "keys": ["super+r"], "command": "build", "context":
[
{ "key": "selector", "operator": "equal", "operand": "source.pde" }
@danielronnkvist
danielronnkvist / part1.m
Created December 6, 2014 09:40
Lab 2 TNM087
%% A
cWhite = imread('CWhite1.jpg');
hWhite = imread('HWhite1.jpg');
N = 512
cWhite512 = imresize(cWhite, [512 512]);
hWhite512 = imresize(hWhite, [512 512]);
[X,Y] = meshgrid((1:N));
[T,R] = cart2pol(X-N/2, Y-N/2);
plot(R(N/2, :));
@danielronnkvist
danielronnkvist / writing_lab_reports.md
Created November 21, 2014 09:23
From a lecture 2014-11-20

Writing lab reports

Lecture by Shelly Torgnyson, 2014-11-20

Do as much work as possible for the draft session. Have questions ready before the five minute session with Shelly.

Simple report structure

  • Title page
@danielronnkvist
danielronnkvist / makeHDR.m
Last active August 29, 2015 14:10
makeHDR
tic
clear all
load('gfun.mat');
ffun= (2.^gfun);
finalpic(:,:,:) = zeros(683,1024,3);
for i=1:14
value = imread(strcat('Img', int2str(i), '.tiff'));
if value > 127
value = 255-value;
end
% Bob lab 1
clear all
%% Load and plot gfun
load('gfun.mat');
plot(gfun)
figure
plot(2.^gfun)

CV

Try to fit all content on to one page.

Don't really mind about gaps in years between experienxe in your CV. It can easilly be explained in an interview.

Make sure your links are clickabl e.