Skip to content

Instantly share code, notes, and snippets.

View nmakes's full-sized avatar
🎯
Focusing

Naveen Venkat nmakes

🎯
Focusing
View GitHub Profile
@nmakes
nmakes / ransac.py
Last active November 4, 2021 01:03
A generalized RANSAC algorithm to fit any arbitrary function (see Example)
"""
Implements the RANSAC Algorithm (https://en.wikipedia.org/wiki/Random_sample_consensus)
Written By: Naveen Venkat (naveenvenkat.com)
School of Computer Science, Carnegie Mellon University
"""
import matplotlib.pyplot as plt
import numpy as np
@nmakes
nmakes / pytorch_count_parameters.py
Last active November 2, 2021 03:26
Count number of parameters in a pytorch model
'''
Count the number of parameters in a pytorch model.
Written for pytorch (cuda compatible).
Written by: Naveen Venkat (naveenvenkat.com)
'''
def count_params(model):
tot = 0
for p in model.parameters():
@nmakes
nmakes / ellipsoid_sampler.py
Last active December 6, 2019 08:05
Perform Uniform Sampling within an N-dimensional ellipsoid.
'''
Perform Uniform Sampling within an N-dimensional ellipsoid.
Written for pytorch (cuda compatible).
Written by Naveen Venkat.
nav.naveenvenkat@gmail.com
naveenvenkat.com
'''
import torch
@nmakes
nmakes / idea.log
Created May 27, 2017 05:36
android app log
2017-05-25 17:41:35,000 [19280050] WARN - ect.sync.idea.ProjectSetUpTask -
2017-05-25 17:41:35,000 [19280050] INFO - ect.sync.idea.ProjectSetUpTask - Cannot add extension with name 'android', as there is an extension already registered with that name.
Consult IDE log for more details (Help | Show Log)
2017-05-25 17:41:35,001 [19280051] INFO - e.project.sync.GradleSyncState - Sync with Gradle for project 'bPMonitor' failed: Cannot add extension with name 'android', as there is an extension already registered with that name.
Consult IDE log for more details (Help | Show Log)
2017-05-25 17:41:35,106 [19280156] INFO - #com.jetbrains.cidr.lang - Clearing symbols finished in 0 s.
2017-05-25 17:41:35,110 [19280160] INFO - #com.jetbrains.cidr.lang - Loading symbols finished in 0 s.
2017-05-25 17:41:35,113 [19280163] INFO - #com.jetbrains.cidr.lang - Building symbols finished in 0 s.
@nmakes
nmakes / GradleConsoleOutput.txt
Created May 25, 2017 15:22
Gradle Console Output for Android App - Help Needed
* Exception is:
org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':mergeDebugResources'.
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:98)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:68)
at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:62)
at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:58)
at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:88)
at org.gradle.api.internal.tasks.execution.ResolveTaskArtifactStateTaskExecuter.execute(ResolveTaskArtifactStateTaskExecuter.java:46)
at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:51)
at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(
@nmakes
nmakes / README.md
Created February 16, 2017 12:05 — forked from oodavid/README.md
Deploy your site with git

Deploy your site with git

This gist assumes:

  • you have a local git repo
  • with an online remote repository (github / bitbucket etc)
  • and a cloud server (Rackspace cloud / Amazon EC2 etc)
    • your (PHP) scripts are served from /var/www/html/
    • your webpages are executed by apache
  • apache's home directory is /var/www/