Skip to content

Instantly share code, notes, and snippets.

Kyle Tolle kyletolle

Block or report user

Report or block kyletolle

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
@kyletolle
kyletolle / fulcrum_projects_example.json
Last active Aug 29, 2015
Fulcrum Example Projects
View fulcrum_projects_example.json
{
"current_page": 1,
"per_page": 20000,
"projects": [
{
"created_at": "2014-05-07T19:17:42Z",
"description": "Data collected that is in the Denver, CO area.",
"id": "3bc943c3-6477-4010-a876-85fce6fdf11",
"name": "Denver",
"updated_at": "2014-05-07T19:17:42Z"
View fulcrum_example_record.json
{
"record": {
"altitude": null,
"assigned_to": null,
"assigned_to_id": null,
"client_created_at": "2014-04-09T12:24:36Z",
"client_updated_at": "2014-04-09T12:26:50Z",
"course": null,
"created_at": "2014-04-28T20:38:46Z",
"created_by": "Kyle Tolle",
View fulrum_form_example.json
{
"form": {
"auto_assign": false,
"bounding_box": [
48.8518638,
2.3130969889462,
48.8772149651485,
2.3516665
],
"created_at": "2014-04-21T21:29:01Z",
View gist:9939366
RubyProf.start
# Code to profile...
result = RubyProf.stop
# Print a graph to an HTML file, sorted by time spend in children.
File.open('profile_output.html', 'w') do |file|
printer = RubyProf::GraphHtmlPrinter.new result
printer.print(file, sort_method: :children_time)
@kyletolle
kyletolle / photo_upload_response.json
Last active Aug 29, 2015
Uploading a photo to Fulcrum from Python
View photo_upload_response.json
// This is the response from the call, reformatted for readability.
{
"photo": {
"access_key": "f37be52e-06d2-418a-916d-0e5874a0de29",
"created_at": "2014-03-10T20:54:26Z",
"created_by": "Kyle Tolle",
"created_by_id": "51efe7d6a93448fc300048d9",
"exif": {
"pixel_x_dimension": 1090,
@kyletolle
kyletolle / deep_each.rb
Last active Feb 19, 2019
deep_each.rb - a multidimensional each for Ruby
View deep_each.rb
two_d_grid =
[
[ 1, 2, 3, 4, 5 ],
[ 6, 7, 8, 9, 10 ],
[ 11, 12, 13, 14, 15]
]
puts "Basic 2D each"
two_d_grid.each do |row|
row.each do |cell|
View alleys.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@kyletolle
kyletolle / README.md
Created Jan 23, 2014
US States Colored by Name Length
View README.md
@kyletolle
kyletolle / README.md
Created Jan 22, 2014
US States Colored by Name Length
@kyletolle
kyletolle / no_side_effects.rb
Created Oct 24, 2013
Which method of internal processing looks or feels best? Were the internal methods used have side effects, or no?
View no_side_effects.rb
def Cherry
def initialize(cherry)
@cherry = cherry
end
def process
@cherry = remove_pit(@cherry)
@cherry = twist_stem(@cherry)
end
You can’t perform that action at this time.