Skip to content

Instantly share code, notes, and snippets.

View firatkarakusoglu's full-sized avatar

Firat Karakusoglu firatkarakusoglu

View GitHub Profile
@firatkarakusoglu
firatkarakusoglu / min-char-rnn.py
Created August 24, 2017 21:09 — forked from karpathy/min-char-rnn.py
Minimal character-level language model with a Vanilla Recurrent Neural Network, in Python/numpy
"""
Minimal character-level Vanilla RNN model. Written by Andrej Karpathy (@karpathy)
BSD License
"""
import numpy as np
# data I/O
data = open('input.txt', 'r').read() # should be simple plain text file
chars = list(set(data))
data_size, vocab_size = len(data), len(chars)
@firatkarakusoglu
firatkarakusoglu / gist:663ed47237f9c392a4423cfa2ea11b79
Created April 29, 2016 12:00 — forked from shanselman/gist:5422230
Evil Blog Comment Spammer just exposed his template through some error and the whole thing showed up in my comments.
{
{I have|I've} been {surfing|browsing} online more than {three|3|2|4} hours today, yet I never found any interesting article like yours. {It's|It
is} pretty worth enough for me. {In my opinion|Personally|In my view}, if all {webmasters|site owners|website owners|web owners} and bloggers made good content as
you did, the {internet|net|web} will be {much more|a lot more}
useful than ever before.|
I {couldn't|could not} {resist|refrain from} commenting. {Very well|Perfectly|Well|Exceptionally well} written!|
{I will|I'll} {right away|immediately} {take hold of|grab|clutch|grasp|seize|snatch}
your {rss|rss feed} as I {can not|can't} {in finding|find|to find} your {email|e-mail} subscription {link|hyperlink} or {newsletter|e-newsletter} service. Do {you have|you've} any?
{Please|Kindly} {allow|permit|let} me {realize|recognize|understand|recognise|know} {so that|in order that} I {may just|may|could} subscribe.
Thanks.|
@firatkarakusoglu
firatkarakusoglu / db-data-config
Created February 11, 2016 09:22 — forked from sebnmuller/db-data-config
Connection config for indexing a database to Solr
<dataConfig>
<dataSource type="JdbcDataSource"
driver="com.mysql.jdbc.Driver"
url="jdbc:mysql://localhost:3306/employees"
user="user"
password="password" />
<document>
<entity name="id" query="select emp_no as 'id', first_name, last_name from employees limit 1000;" />
</document>
</dataConfig>
<?php
/*
* simple HttpRequest example using PHP
* tom slankard
*/
class HttpRequest {
public $url = null;