Skip to content

Instantly share code, notes, and snippets.

View ganni's full-sized avatar
🌍
👩🏻‍💻

Nyamka Ganni (Suren) ganni

🌍
👩🏻‍💻
View GitHub Profile
@tanaikech
tanaikech / submit.md
Last active July 1, 2024 14:18
Converting SVG Format to PNG Format using Google Apps Script

Converting SVG Format to PNG Format using Google Apps Script

This is a sample script for converting the SVG image data to PNG image data using Google Apps Script.

Unfortunately, in the current stage, there are no methods for directly converting the SVG to PNG in Google Drive service. But it can be achieved by Drive API. The sample script is as follows.

Before you use this, please enable Drive API at Advanced Google services.

Sample script

@alanshaw
alanshaw / getElementsState.js
Created July 21, 2017 16:38
Nightwatch commands for getting state of multiple elements
// Get state for multiple elements
// getState is passed an element and should return a promise that gets some state
// e.g. http://nightwatchjs.org/api#elementIdText
// Callback will be called with an array of the state values once they're all resolved
exports.command = function getElementsState (selector, getState, callback) {
this.elements('css selector', selector, function (elements) {
const values = elements.value.map(getState)
Promise.all(values).then(callback)
})
return this
@koorukuroo
koorukuroo / news_rss.py
Last active April 13, 2025 09:35
Korean News RSS URLs
### 출처
# http://blog.opid.kr/427
# 400, 403, 404 에러가 없는 url만 간추림
### 언론사 리스트
# 중앙일보 | 구글뉴스 | 에이빙뉴스 | 중부매일 | 에버뉴스 |
# 경향닷컴 | 데이터넷 | 세계일보 | 뉴스위드 | 뉴스포스트 |
# 르몽드 디플로마티크 | 컨슈머타임스 | MBC | 한국아이닷컴 | 노컷뉴스 |
# K모바일 | 탑라이더 | 한국경제 | 동아닷컴 | 엑스포저널 |
@jkleint
jkleint / timeseries_cnn.py
Created July 29, 2016 04:05
Example of using Keras to implement a 1D convolutional neural network (CNN) for timeseries prediction.
#!/usr/bin/env python
"""
Example of using Keras to implement a 1D convolutional neural network (CNN) for timeseries prediction.
"""
from __future__ import print_function, division
import numpy as np
from keras.layers import Convolution1D, Dense, MaxPooling1D, Flatten
from keras.models import Sequential
@Spencer-Easton
Spencer-Easton / exportSpreadsheet.gs
Last active April 8, 2025 13:39
Example on how to export a Google sheet to various formats, includes most PDF options
function exportSpreadsheet() {
//All requests must include id in the path and a format parameter
//https://docs.google.com/spreadsheets/d/{SpreadsheetId}/export
//FORMATS WITH NO ADDITIONAL OPTIONS
//format=xlsx //excel
//format=ods //Open Document Spreadsheet
//format=zip //html zipped
@balzer82
balzer82 / TimeSeries-Decomposition.ipynb
Last active June 20, 2022 14:38
TimeSeries Decomposition in Python with statsmodels and Pandas
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@soheilhy
soheilhy / nginxproxy.md
Last active May 14, 2025 20:17
How to proxy web apps using nginx?

Virtual Hosts on nginx (CSC309)

When hosting our web applications, we often have one public IP address (i.e., an IP address visible to the outside world) using which we want to host multiple web apps. For example, one may wants to host three different web apps respectively for example1.com, example2.com, and example1.com/images on the same machine using a single IP address.

How can we do that? Well, the good news is Internet browsers

@ijy
ijy / sublime-text-3-setup.md
Last active March 7, 2025 20:44
My Sublime Text 3 setup.

Sublime Text 3 Setup

Install Package Control

Install Package Control for easy package management.

  1. Open the console with Ctrl+`
  2. Paste in the following:
@insin
insin / index.html
Last active October 29, 2024 01:21
Export a <table> to Excel - http://bl.ocks.org/insin/1031969
<!DOCTYPE html>
<html>
<head>
<title>tableToExcel Demo</title>
<script src="tableToExcel.js"></script>
</head>
<body>
<h1>tableToExcel Demo</h1>
<p>Exporting the W3C Example Table</p>
/** Testing sax push parsing
*
* The output file should have almost identical
* to the input file
*
* Known issues with this example output
*
* - Doesn't escape entities. You can do it
* manually on the character content.
* - Doesn't replicate self-closing tags.