Skip to content

Instantly share code, notes, and snippets.

🎰
Coding

Ryein Goddard Goddard

🎰
Coding
Block or report user

Report or block Goddard

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@Goddard
Goddard / main.py
Created Oct 15, 2017
main network file for semantic segmentation
View main.py
import os.path
import tensorflow as tf
import helper
import freeze
import warnings
from distutils.version import LooseVersion
import project_tests as tests
@Goddard
Goddard / video.py
Created Oct 15, 2017
Trying to use a pre-existing model and my additions after saving then restoring and run on video
View video.py
import os.path
import tensorflow as tf
import helper
import cv2
from distutils.version import LooseVersion
# Check TensorFlow Version
assert LooseVersion(tf.__version__) >= LooseVersion('1.0'), 'Please use TensorFlow version 1.0 or newer. You are using {}'.format(tf.__version__)
print('TensorFlow Version: {}'.format(tf.__version__))
View formulagraphing.py
import numpy as np
import matplotlib.pyplot as plt
def graph(formula, x_range):
x = np.array(x_range)
y = formula(x)
plt.plot(x, y)
plt.show()
def my_formula(x):
@Goddard
Goddard / terminal-session
Created Nov 1, 2015 — forked from nlevchuk/terminal-session
It's bash script for saving and loading gnome-terminal session. Special for Ubuntu.
View terminal-session
#!/bin/bash
##
## This is bash script for saving and loading gnome-terminal session. Special for Ubuntu.
##
## Usage: ./terminal-session -s <name_profile> - for save session
## ./terminal-session -l <name_profile> - for load existing session
## ./terminal-session --profiles - for show existing session files
##
## Instructions:
## - Run gnome-terminal;
View uploader2.py
from gdata.youtube import YouTubeVideoEntry
from gdata.youtube.service import YouTubeService
import gdata
from gdata.service import BadAuthentication, CaptchaRequired
from optparse import OptionParser
import sys
import time
import os
View basicResponsive.css
/* Smartphones (portrait and landscape) ----------- */
@media only screen
and (min-device-width : 320px)
and (max-device-width : 480px) {
/* Styles */
}
/* Smartphones (landscape) ----------- */
@media only screen
and (min-width : 321px) {
View imageview.cpp
void ImageView::paintEvent(QPaintEvent*)
{
if (this->imageBuffer.empty()){ return; }
double widgetWidth = this->width();
double widgetHeight = this->height();
QRectF target(0, 0, widgetWidth, widgetHeight);
QImage tempQImage = *this->imageBuffer.at(this->imageBuffer.count()-1);
tempQImage = tempQImage.scaled(rect().size(), Qt::KeepAspectRatio, Qt::SmoothTransformation);
@Goddard
Goddard / form.php
Created Jul 12, 2014
semi-fixed form.php file from ohana
View form.php
<? (defined('_JEXEC') && defined('KOOWA')) or die('Restricted access'); ?>
<style src="media://com_ohanah/lib/cleditor/jquery.cleditor.css" />
<style src="media://com_ohanah/css/jquery-ui.css" />
<style>
.authorInfo {
overflow: hidden;
}
.debug {
color: #555;
margin: 20px;
@Goddard
Goddard / install-node-npm-ubuntu-raring.sh
Created May 2, 2013 — forked from stephanetimmermans/gist:5496788
Install Node Js and NPM in Ubuntu 13.04
View install-node-npm-ubuntu-raring.sh
sudo apt-get install build-essential libssl-dev curl
# The install script
# Adapted from https://gist.github.com/579814
echo '# Added by install script for node.js and npm in 30s' >> ~/.bashrc
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc
echo 'export NODE_PATH=$HOME/local/lib/node_modules' >> ~/.bashrc
. ~/.bashrc
View XMLReader.java
import java.net.URL;
import javax.xml.parsers.SAXParser;
import javax.xml.parsers.SAXParserFactory;
import org.xml.sax.InputSource;
/**
*
* @author goddard
*/
public class XMLReader
You can’t perform that action at this time.