Skip to content

Instantly share code, notes, and snippets.

View SamCarlberg's full-sized avatar

Sam Carlberg SamCarlberg

View GitHub Profile
edu.wpi.grip.core.PipelineTest > testMoveStepToBeginning FAILED
com.google.inject.CreationException: Unable to create injector, see the following errors:
1) No implementation for edu.wpi.grip.core.http.GripServer$HttpServerFactory was bound.
while locating edu.wpi.grip.core.http.GripServer$HttpServerFactory
for parameter 0 at edu.wpi.grip.core.http.GripServer.<init>(Unknown Source)
while locating edu.wpi.grip.core.http.GripServer
for parameter 2 at edu.wpi.grip.core.sources.HttpSource.<init>(Unknown Source)
at edu.wpi.grip.core.sources.HttpSource$Factory.create(Unknown Source)
package edu.wpi.grip.core.operations.composite;
import com.google.common.eventbus.EventBus;
import edu.wpi.grip.core.Operation;
import edu.wpi.grip.core.sockets.InputSocket;
import edu.wpi.grip.core.sockets.OutputSocket;
import edu.wpi.grip.core.sockets.SocketHints;
import java.io.InputStream;
import java.util.Optional;
@SamCarlberg
SamCarlberg / BlurOperation.java
Last active March 31, 2016 19:39
GRIP operation refactoring
package edu.wpi.grip.core.operations.composite;
import edu.wpi.grip.core.Operation;
import edu.wpi.grip.core.OperationDescriptor;
import edu.wpi.grip.core.sockets.InputSocket;
import edu.wpi.grip.core.sockets.OutputSocket;
import edu.wpi.grip.core.sockets.SocketHint;
import edu.wpi.grip.core.sockets.SocketHints;
import edu.wpi.grip.core.util.Icons;
Apr 12, 2016 1:05:45 PM edu.wpi.grip.core.util.service.LoggingListener starting
INFO: [CameraSource] Starting
Apr 12, 2016 1:05:45 PM edu.wpi.grip.core.util.service.LoggingListener failed
SEVERE: [CameraSource] Failed from: STARTING
edu.wpi.grip.core.sources.GrabberService$GrabberServiceException: [Webcam 0] Failed to start
at edu.wpi.grip.core.sources.GrabberService.startUp(GrabberService.java:51)
at com.google.common.util.concurrent.AbstractExecutionThreadService$1$2.run(AbstractExecutionThreadService.java:54)
at com.google.common.util.concurrent.Callables$3.run(Callables.java:100)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.bytedeco.javacv.FrameGrabber$Exception: cvCreateCameraCapture() Error: Could not create camera capture.
diff --git a/core/src/main/java/edu/wpi/grip/core/operations/composite/PublishVideoOperation.java b/core/src/main/java/edu/wpi/grip/core/operations/composite/PublishVideoOperation.java
index 4363098..8fd49c2 100644
--- a/core/src/main/java/edu/wpi/grip/core/operations/composite/PublishVideoOperation.java
+++ b/core/src/main/java/edu/wpi/grip/core/operations/composite/PublishVideoOperation.java
@@ -1,17 +1,17 @@
package edu.wpi.grip.core.operations.composite;
-import com.google.common.eventbus.EventBus;
-import edu.wpi.grip.core.sockets.InputSocket;
import edu.wpi.grip.core.Operation;
<code_scheme name="IntelliJ formatting settings">
<option name="CLASS_COUNT_TO_USE_IMPORT_ON_DEMAND" value="999" />
<option name="NAMES_COUNT_TO_USE_IMPORT_ON_DEMAND" value="999" />
<option name="PACKAGES_TO_USE_IMPORT_ON_DEMAND">
<value />
</option>
<option name="IMPORT_LAYOUT_TABLE">
<value>
<package name="sun" withSubpackages="true" static="false" />
<emptyLine />
------------------------------------------------------------
Root project
------------------------------------------------------------
:check
+--- :checkstyleMain
| \--- :classes
| +--- :compileJava
| \--- :processResources
+--- :checkstyleTest
<code_scheme name="Project">
<option name="CLASS_COUNT_TO_USE_IMPORT_ON_DEMAND" value="999" />
<option name="NAMES_COUNT_TO_USE_IMPORT_ON_DEMAND" value="999" />
<option name="PACKAGES_TO_USE_IMPORT_ON_DEMAND">
<value />
</option>
<option name="IMPORT_LAYOUT_TABLE">
<value>
<package name="edu.wpi.grip" withSubpackages="true" static="false" />
<emptyLine />
"JavaFX Application Thread" #13 prio=5 os_prio=0 tid=0x00007f6fc02a3000 nid=0x1bd9 waiting on condition [0x00007f6f4fd36000]
java.lang.Thread.State: WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for <0x00000000dbb67ab0> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitUninterruptibly(AbstractQueuedSynchronizer.java:1976)
at com.google.common.util.concurrent.Monitor.awaitUninterruptibly(Monitor.java:1102)
at com.google.common.util.concurrent.Monitor.enterWhenUninterruptibly(Monitor.java:473)
at com.google.common.util.concurrent.AbstractService.awaitTerminated(AbstractService.java:278)
at com.google.common.util.concurrent.AbstractScheduledService.awaitTerminated(AbstractScheduledService.java:403)
import cv2
from vision_api import *
class StubPipeline(VisionPipeline):
def __init__(self):
self.output = None
def process(self, image: np.ndarray) -> None:
self.output = image # Sets the 'output'