Skip to content

Instantly share code, notes, and snippets.

View BenMatheja's full-sized avatar
🎯
Focusing

Ben Matheja BenMatheja

🎯
Focusing
  • Dr. ing. h.c. F. Porsche AG
  • Stuttgart
View GitHub Profile
@BenMatheja
BenMatheja / gist:9230138
Last active May 24, 2023 05:00
mopidy port 80 proxy pass with nginx on raspberry pi
sudo apt-get update
sudo apt-get install nginx
sudo service nginx start
sudo vi /etc/nginx/sites-enabled/default
##### VI output, oder nano jenachdem mit was du die ändern willst ###
server {
#listen 80; ## listen for ipv4; this line is default and implied
#listen [::]:80 default_server ipv6only=on; ## listen for ipv6
@BenMatheja
BenMatheja / config.gateway.json
Last active December 5, 2020 21:21
This USG configuration Redirects DNS traffic to my pihole at .9, .10 and .11. In addition forwarded traffic is disguised so the client will not recognize that he did not hit 8.8.8.8
{
"service": {
"nat": {
"rule": {
"1": {
"description": "DNS Redirect to pihole",
"destination": {
"address": "!192.168.1.1-192.168.1.11",
"port": "53"
},

Keybase proof

I hereby claim:

  • I am benmatheja on github.
  • I am benmatheja (https://keybase.io/benmatheja) on keybase.
  • I have a public key whose fingerprint is A6C0 3B7C 3C79 89BC 55A2 E0DB 51AD 55C9 A872 7DD0

To claim this, I am signing this object:

estimatePeaks = function (dfOfClusters) {
# helper: source: https://github.com/kerschke/flacco/blob/master/R/feature_ela_distribution.R
number_of_peaks = function(x, smoothing.bandwidth = "SJ", modemass.threshold = 0.01, ...) {
intdens = function(a, b) {
mean(y[a:b]) * diff(d$x[c(a, b)])
}
d = density(x, bw = smoothing.bandwidth, ...)
y = d$y
n = length(y)
index = 2L : (n - 1L)
2016/02/16 18:16:02 [INFO] EOLIS - Beginne das HLB-Testdatenset zu erzeugen.
2016/02/16 18:16:03 [INFO] EOLIS - Retrieving technical feasible battery<->scenario assignments for 89 scenarios and 200 batteries
Loading required package: slam
Using the GLPK callable library version 4.47
2016/02/16 18:35:50 [INFO] EOLIS - Found technical feasible batteries for 86 scenarios
----------------------
New Assignment - Battery Leaf BatteryPack and Zwischenspeicher
Beginning Creation of Variant 1
Minimum Configuration added following services
16 Gewährleistung 2 Jahre
CREATE TABLE Infinity.activity_instance (oid BIGINT AUTO_INCREMENT PRIMARY KEY, state INT, startTime BIGINT, lastModificationTime BIGINT, model BIGINT, activity BIGINT, currentPerformer BIGINT, currentUserPerformer BIGINT, performedBy BIGINT, currentDepartment BIGINT, processInstance BIGINT) TYPE=InnoDB;
CREATE UNIQUE INDEX activity_inst_idx1 ON Infinity.activity_instance(oid);
CREATE INDEX activity_inst_idx2 ON Infinity.activity_instance(currentPerformer, currentDepartment);
CREATE INDEX activity_inst_idx3 ON Infinity.activity_instance(currentUserPerformer, currentPerformer, currentDepartment);
CREATE INDEX activity_inst_idx4 ON Infinity.activity_instance(performedBy);
CREATE INDEX activity_inst_idx5 ON Infinity.activity_instance(processInstance);
CREATE INDEX activity_inst_idx6 ON Infinity.activity_instance(startTime, activity, state);
CREATE INDEX activity_inst_idx7 ON Infinity.activity_instance(state);
CREATE INDEX activity_inst_idx8 ON Infinity.activity_instance(activity, processInstance);
@echo off
rem Carnot application launch script
rem (C) 2000-2011 SunGard CSA LLC
rem
rem You can affect the behaviour of this script with the following environment variables
rem described in the CARNOT documentation:
rem
rem CARNOT_HOME: The location of the carnot distribution
rem CARNOT_WORK: The location of your private settings
rem CARNOT_CLASSPATH: A fixed classpath to use if you want to prevent automatic classpath assembly
@BenMatheja
BenMatheja / gist:6149886
Created August 4, 2013 09:44
HSQL - Logfile for bodega - Inserts working
/*C2*/SET SCHEMA PUBLIC
DISCONNECT
/*C3*/SET SCHEMA PUBLIC
create table Edge (ID bigint generated by default as identity (start with 1), CAPTION varchar(255) not null, end_ID bigint, start_ID bigint, primary key (ID))
create table Language (ID bigint generated by default as identity (start with 1), DESC varchar(255) not null, TITLE varchar(255) not null, primary key (ID))
create table Language_MODEL (Language_ID bigint not null, models_ID bigint not null, primary key (Language_ID, models_ID), unique (models_ID))
create table MODEL (ID bigint generated by default as identity (start with 1), TITLE varchar(255), language_ID bigint, primary key (ID))
create table MODEL_Edge (Model_ID bigint not null, edges_ID bigint not null, primary key (Model_ID, edges_ID), unique (edges_ID))
create table Project (ID bigint generated by default as identity (start with 1), primary key (ID))
create table Vertex (ID bigint generated by default as identity (start with 1), caption varchar(255) not null, primary key (ID))
After import eclipse might complain about different java facets version.
Solution: In the properties of the affected project, choose Project Facets on the left side and change the Java version to use to 1.6
-persistence-test project displays a high number of various errors after import
no solution, but apparently not necessary to run the project
After trying to refactor the project names, an XML Problem (Attribute "xmlns" was already specified for element "web-app".) appears for -Web project
Solution: remove one xmlns definition in line 2 of the web.xml
At server startup, it might complain in the console about missing hsql dependencies
@BenMatheja
BenMatheja / gist:10068241
Last active August 29, 2015 13:58
CUPS Configuration for RaspberryPI
#
# "$Id: cupsd.conf.in 9407 2010-12-09 21:24:51Z mike $"
#
# Sample configuration file for the CUPS scheduler. See "man cupsd.conf" for a
# complete description of this file.
#
# Log general information in error_log - change "warn" to "debug"
# for troubleshooting...
LogLevel warn