Skip to content

Instantly share code, notes, and snippets.

View Cospel's full-sized avatar

Michal Lukac Cospel

View GitHub Profile
@Cospel
Cospel / hltrace
Created June 10, 2011 12:08
Converting text from strace to html.
#!/bin/sh
#
# Nazov : hltrace, B. Zvyraznenie syntaxe
# Autor : Michal Lukac, xlukac05@stud.fit.vutbr.cz
# Datum : 10.3.2011
# Info : Tento skript sluzi ako prvy projekt pre predmet IOS na VUT FIT.
# Ulohou tohoto skriptu je zvyraznovanie syntaxe textu zaznamenaneho
# pomocou strace a vystupom je HTML stranka.
# P.riadkov: 107
# Testovane: na systemoch FREEBSD, LINUX, SOLARIS
@Cospel
Cospel / gist:1018742
Created June 10, 2011 12:21
Sorting czech items.
/*
* Súbor : proj4.c
* Dátum : 11.12.2010
* Autor : Michal Lukáč, xlukac05@stud.fit.vutbr.cz
* Projekt : Projekt č.4. České radenie záznamov.
* Popis : Tento projekt je projektom do predmetu základy programovania.
* P.riadkov: 741
*/
#include <stdio.h>
@Cospel
Cospel / ardiff.sh
Created June 10, 2011 12:23
Show/Make diff btw two archives.
#!/bin/sh
#
# Nazov : ardiff, A.Prace s archivy
# Autor : Michal Lukac, xlukac05@stud.fit.vutbr.cz
# Datum : 16.3.2011
# Info : Tento skript sluzi ako prvy projekt pre predmet IOS na VUT FIT.
# Ulohou tohoto skriptu je praca s archivami ich porovnavanie,
# ukladanie a aplikaciami zmen.
# P.riadkov: 231
# Testovane: na systemoch FREEBSD, LINUX, SOLARIS
@Cospel
Cospel / barbers.c
Created June 10, 2011 12:24
Implementation of barbers problem.
/**
* Program: barbers
* Datum : 10.4.2011
* @author: Michal Lukac, xlukac05@stud.fit.vutbr.cz
* @file : barbers.c
* @brief : Projekt do predmetu IOS na VUT FIT. Ulohou je synchronizacia
* procesov problemu spiaceho holica.
*/
#include <stdio.h>
@Cospel
Cospel / Convert.cs
Last active August 29, 2015 14:24
convert
using System;
using System.IO;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Groupdocs.Web.UI.Conversion;
using Groupdocs.Common;
namespace TestGroup
%!
% This is a sample prefix file for creating a PDF/A document.
% Feel free to modify entries marked with "Customize".
% This assumes an ICC profile to reside in the file (ISO Coated sb.icc),
% unless the user modifies the corresponding line below.
% Define entries in the document Info dictionary :
/ICCProfile (/usr/share/ghostscript/9.07/iccprofiles/ISOcoated_v2_300_eci.icc) % Customize.
@Cospel
Cospel / pdfa
Created September 22, 2015 15:11
http://www.ghostscript.com/download/gsdnld.html
http://www.linuxquestions.org/questions/linux-software-2/install-ghostscript-v-9-05-or-newer-on-centos-4175465563/
http://stackoverflow.com/questions/17079750/ghostscript-9-07-pdf-x-1a2001-pdf-x-output-intent-is-missing
http://help.fabasoftfolio.com/index.php?topic=doc/Fabasoft-on-Linux---Installation-of-Fabasoft-Folio-Services/install-and-configure-gpl-ghostscript.htm
http://stackoverflow.com/questions/26040997/convert-pdf-files-to-pdf-a-via-ghostscript
http://digital-preservation.github.io/droid/
http://thisthatisnot.blogspot.cz/2010/04/free-way-to-convert-existing-pdf-to.html
http://unix.stackexchange.com/questions/79516/converting-pdf-to-pdf-a
http://svn.ghostscript.com/ghostscript/trunk/gs/doc/Ps2pdf.htm#PDFA
http://stackoverflow.com/questions/1659147/how-to-use-ghostscript-to-convert-pdf-to-pdf-a-or-pdf-x
Na centos som mal uz nainstalovany ghostscript(avsak kebyze nesiel spodny prikaz tak treba nainstalovat co najnovsiu verziu)
yum install ghostscript
Priklad dokumentu na konverziu:
www.pdf995.com/samples/pdf.pdf
www.cbu.edu.zm/downloads/pdf-sample.pdf
# Prikaz na konverziu ktory skus:
# Pouzivam najnvovsiu verziu ghostscriptu 9.16
@Cospel
Cospel / rbm_MNIST_test.py
Last active October 27, 2017 11:13 — forked from myme5261314/rbm_MNIST_test.py
RBM procedure using tensorflow
#http://blog.echen.me/2011/07/18/introduction-to-restricted-boltzmann-machines/
#https://www.tensorflow.org/versions/r0.7/api_docs/python/constant_op.html#random_uniform
import tensorflow as tf
import numpy as np
import input_data
import Image
from util import tile_raster_images
@Cospel
Cospel / rbm_after_refactor.py
Created April 3, 2016 13:46 — forked from gabrieleangeletti/rbm_after_refactor.py
Restricted Boltzmann Machine implementation in TensorFlow, before and after code refactoring. Blog post: http://www.gabrieleangeletti.com/blog/programming/2016/02/21/refactoring-rbm-tensor-flow-implementation.html
import tensorflow as tf
import numpy as np
import os
import zconfig
import utils
class RBM(object):