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
| % http://stackoverflow.com/questions/27693593/color-correcting-images-in-matlab | |
| % https://ia802707.us.archive.org/23/items/Lectures_on_Image_Processing/EECE253_05_ColorCorrection.pdf | |
| close all; | |
| clear all; | |
| im1 = imread('http://i.stack.imgur.com/GtgHU.jpg'); | |
| im2 = imread('http://i.stack.imgur.com/wHW50.jpg'); | |
| rng(123); %// Set seed for reproducibility | |
| num_colours = 2000; | |
| ind = randperm(numel(im1) / size(im1,3), num_colours); |
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
| td= truncate(period.program.name, length: 30) | |
| td= truncate(period.name, length: 47) | |
| td= period.code | |
| td | |
| - if can? :read, Student | |
| = link_to "Öğrenciler", students_admin_period_path(period) | |
| span | | |
| = link_to (t "general.show"), [:admin, period] | |
| - if can? :update, Period | |
| span | |
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
| class Attachment < ActiveRecord::Base | |
| mount_uploader :attachment, AttachmentUploader | |
| # Associations | |
| belongs_to :attached_item, polymorphic: true | |
| # Validations | |
| validates_presence_of :attachment |
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
| [mysqld] | |
| # ---------------------------------------------------------------------- | |
| # UTF-8 temiz bir mysql için ilgili yapılandırma | |
| # ---------------------------------------------------------------------- | |
| init_connect=’SET collation_connection = utf8_general_ci’ | |
| init_connect=’SET NAMES utf8′ | |
| character-set-server=utf8 | |
| collation-server=utf8_general_ci |
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
| // Use Gists to store code you would like to remember later on | |
| console.log(window); // log the "window" object to the console |
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
| # coding: utf-8 | |
| require 'savon' | |
| require 'awesome_print' | |
| class KPSSorgu | |
| # T.C. Kimlik ile Kişi Sorgulama - Konfigürasyon | |
| @@tc_bilgi_client = Savon.client( | |
| wsdl: "http://192.168.33.25/KPSService/servicetckimliksorgula.asmx?WSDL", | |
| namespace: "http://tempuriTCKimlik.org/", |
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
| s = Stack() | |
| s.push('Ruby') | |
| s.push('Perl') | |
| s.push('Go') | |
| while not s.isEmpty(): | |
| s.pop() | |
| s.pop() |
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
| clc | |
| as = input('Arasinav'); | |
| ds = input('Final'); | |
| ort = as * 40/100 + ds * 60/100 | |
| clc | |
| disp('Vucut-Kitle Index Hesaplama Programina Hosgeldiniz'); | |
| boy = input('Boyunuz: '); | |
| kilo = input('Kilonuz: '); |
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
| - max | |
| - mutlak | |
| - BMI | |
| - Hal (katı, sıvı, gaz) | |
| - Ortalama: geçti, kaldı |
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
| clear all; close all; clc; | |
| im = imread('http://i.imgur.com/TwDQZKO.jpg'); | |
| r = im(:,:, 1); | |
| g = im(:,:, 2); | |
| b = im(:,:, 3); | |
| figure(1); | |
| subplot(2,2,1); imshow(im); title('Boninon'); |