Category Archives: Software

How to switch divs on or off – a super neat trick

I want to hide a div container as it clutters my otherwise clean picture display. And I found some javascript – free, CSS only solution: the checkbox hack. Modified it a bit while it looks now like this

<label for="t">license me...</label>
<input id="t" type="checkbox" />
<div id="buy">price</div>
input[type=checkbox] {position: absolute;
 top: -9999px; left: -9999px; }
label { border:none; cursor: pointer; }
label:hover { border-bottom:1px solid #444; }
div#buy { display:none; }
input[type=checkbox]:checked ~ div#buy
 { display: block; }

You get the idea: whenever the label of the unvisible checkbox is being clicked, the display state of the div container is changing between on to off.

 

CC-BY-NC Science Surf , accessed 24.08.2026

The brain is not a computer

aeon.co/essays has a a long and convincing plea

Our shoddy thinking about the brain has deep historical roots, but the invention of computers in the 1940s got us especially confused. For more than half a century now, psychologists, linguists, neuroscientists and other experts on human behaviour have been asserting that the human brain works like a computer … we are not born with: information, data, rules, software, knowledge, lexicons, representations, algorithms, programs, models, memories, images …
computers really do operate on symbolic representations of the world. They really store and retrieve. They really process. They really have physical memories. They really are guided in everything they do, without exception, by algorithms…
The idea that memories are stored in individual neurons is preposterous: how and where is the memory stored in the cell?

Indeed, all NMR studies tell us, that many brain areas are being involved in simple tasks. I just wonder why all the current research money goes into human brain mapping projects? We know, it doesn’t work and it is not just a matter of poor organization.

I particular liked the objection of aeon.co that human consciousness acts like computer software. Just bits and bytes get immoral as shown in the movie Transcendence (2014) with disastrous results for humanity. Or like with the Twitter bot Tay that had to be shut down due to its inability to recognize when it was making offensive or racist statements.

 

CC-BY-NC Science Surf , accessed 24.08.2026

owncloud 9.0.2 destroyed

Again, the recent own cloud 8 -> 9 updates remained difficult. Modifying the database helped:

update oc_appconfig set configvalue = 'dav/appinfo/v1/webdav.php' where appid = 'core' and configkey = 'remote_files';
update oc_appconfig set configvalue = 'dav/appinfo/v1/webdav.php' where appid = 'core' and configkey = 'remote_webdav';
update oc_appconfig set configvalue = 'dav/appinfo/v1/caldav.php' where appid = 'core' and configkey = 'remote_calendar';
update oc_appconfig set configvalue = 'dav/appinfo/v1/caldav.php' where appid = 'core' and configkey = 'remote_caldav';
update oc_appconfig set configvalue = 'dav/appinfo/v1/carddav.php' where appid = 'core' and configkey = 'remote_contacts';
update oc_appconfig set configvalue = 'dav/appinfo/v1/carddav.php' where appid = 'core' and configkey = 'remote_carddav';
update oc_appconfig set configvalue = 'dav/appinfo/v1/carddav.php' where appid = 'core' and configkey = 'remote_contactsplus';

But only to discover that the new calendar entries were corrupt as found by others

/* show old calendars and count */
SELECT o.calendarid, c.userid, c.displayname, c.uri, COUNT(o.calendarid)
FROM oc_clndr_objects o
JOIN oc_clndr_calendars c ON o.calendarid = c.id
GROUP BY calendarid
ORDER BY c.userid, c.displayname;
/* show new calendars and count */
SELECT o.calendarid, c.principaluri, c.displayname, c.uri, COUNT(o.calendarid)
FROM oc_calendarobjects o
JOIN oc_calendars c ON o.calendarid = c.id
GROUP BY calendarid
ORDER BY c.principaluri, c.displayname;

Maybe I give up on own cloud now.

 

CC-BY-NC Science Surf , accessed 24.08.2026

Vermessen

Vermessen hast reichlich widersprüchliche Bedeutungen. Zum einen bedeutet vermessen aktiv – ich bestimme die genauen Maße. Dagegen bedeutet, ich habe mich vermessen, ich habe etwas falsch gemessen. Und als Adjektiv gibt es nochmal eine andere Bedeutung: ich bin vermessen, meint ich bin überheblich. Continue reading Vermessen

 

CC-BY-NC Science Surf , accessed 24.08.2026

Irreproducibility, once more

Francis Collins wrote in a commentary

A growing chorus of concern, from scientists and laypeople, contends that the complex system for ensuring the reproducibility of biomedical research is failing and is in need of restructuring. As leaders of the US National Institutes of Health (NIH), we share this concern and here explore some of the significant interventions that we are planning.
Science has long been regarded as ‘self-correcting’, given that it is founded on the replication of earlier work. Over the long term, that principle remains true. In the shorter term, however, the checks and balances that once ensured scientific fidelity have been hobbled. This has compromised the ability of today’s researchers to reproduce others’ findings.
Let’s be clear: with rare exceptions, we have no evidence to suggest that irreproducibility is caused by scientific misconduct. In 2011, the Office of Research Integrity of the US Department of Health and Human Services pursued only 12 such cases3. Even if this represents only a fraction of the actual problem, fraudulent papers are vastly outnumbered by the hundreds of thousands published each year in good faith.

I agree, that a major part of current research output is not reproduced anymore.

Furthermore, there are doubts that science is self-correcting anymore even on the long-term run. Who will ever assemble 500K GWAS data 50.000 asthma patients and another 50.000 controls? Sharing data is the only solution to discover any false claims. Unfortunately, I could even not even get within an EU FP 5 project the genotype data from my own probands.

And let’s be clear: was is scientific misconduct? Just fraud or the long slippery slope?

According to the FDAAA, failure to comply with its provisions may result in civil penalties of as much as $10 000 per day.

Maybe the EU should implement a similar policy like the FDAAA??

 

CC-BY-NC Science Surf , accessed 24.08.2026

Aber wir sind doch alles Tiroler

Am Brenner heute morgen im Fernbus von Bozen nach München. Zwei österreichische Polizeibeamte gehen durch die Reihen und kontrollieren die Ausweise. Eine alte Frau ganz vorne in der ersten Reihe ganz entsetzt zu dem doch recht jovialen Polizisten: Aber wir sind doch alle Tiroler!

20160402_160528__DSC4998

gesehen in Wien / Josefstadt Anfang April

 

CC-BY-NC Science Surf , accessed 24.08.2026

Raspberry Infrared: Just 50€ to detect a frame motor?

At the recent bike festival Sattelfest here in Munich, I had the chance to try out an in frame electric motor Vivax Assist. The wheel was spinning slowly leading to a seat stay temperature difference of at least 5 degree Celsius compared to the top tube. There was also a clear gradient towards to the bottom bracket that should be visible with conventional thermography.
You could use the Seek Thermal Smartphone add ons for thermography (249€) while also Raspberry just released an updated camera sensor with no IR filter (23€). Unfortunately 1um wave length is way ahead from the 3um IR wavelength required for thermal imaging but there is also a 16×4 array sensor MLX90620 from Melexis that could work. Could anyone take some pictures of race bikes next week during the start of the Giro?

 

CC-BY-NC Science Surf , accessed 24.08.2026

Link collection homomorphic encryption algorithm

… is a form of encryption that allows computations to be carried out on ciphertext, thus generating an encrypted result which, when decrypted, matches the result of operations performed on the plaintext…

First publication: acm.org
Introduction: technologyreview.com
Details: en.wikipedia.org
Use in genomics: nature.com
R package: www.louisaslett.com

install.packages(c("Rcpp", "RcppParallel", "gmp")) 
install.packages("http://www.louisaslett.com/HomomorphicEncryption/dl/HomomorphicEncryption_0.2.tgz", repos=NULL)
library("HomomorphicEncryption")
p <- pars("FandV")
k <- keygen(p)
c1 <- enc(k$pk, c(42,34))
c2 <- enc(k$pk, c(7,5))
cres1 <- c1 + c2
cres2 <- c1 * c2
cres3 <- c1 %*% c2
dec(k$sk, cres1)
dec(k$sk, cres2)
dec(k$sk, cres3)

 

CC-BY-NC Science Surf , accessed 24.08.2026

No, there are no super humans

A new study – repeated by many newspapers – claims genes that rescue even in severe Mendelian disorder: cystic fibrosis, Smith-Lemli-Opitz syndrome, familial dysautonomia, epidermolysis bullosa simplex, Pfeiffer syndrome, autoimmune polyendocrinopathy syndrome, acampomelic campomelic dysplasia and atelosteogenesis.

A comprehensive screen of 874 genes in 589,306 genomes led to the identification of 13 adults harboring mutations for 8 severe Mendelian conditions, with no reported clinical manifestation of the indicated disease.

But we know about the reliability of 23andme results

Finally! 23 and the FDA warning

who even mixed up samples in the past.

Searching for genes that makes your resilient to disease is interesting of course but not very new with more examples of cystic fibrosis survivors available. Any new proof by the 23andme study is missing so far as the authors were unable to recontact any of the 13 resilient indiviuduals for whatever reasons.

 

CC-BY-NC Science Surf , accessed 24.08.2026

Up- and download in a single page application

This still not a trivial task given the patchwork of code pieces floating around. When writing a route finder app I came up with the following solution

# html
<form id="myform" enctype="multipart/form-data" action="upload.php" method="POST" target="_parent">
  <input type="hidden" name="uuid" value="1"/>
  <input id="myfile" type="file" name="file"  style="display: none;"/>
  <input type="submit" value="send" style="display: none;"/>
</form>

# query javascript that starts the upload
$("input[id='myfile']").click();

# upload.php
# note the redirect with javascript not with php allows to pass state parameters
$uuid=htmlspecialchars($_POST["uuid"]);
$uf = basename($_FILES['file']['name']);
$fn='data/'.$uuid.'.gpx';
if (move_uploaded_file($_FILES['file']['tmp_name'], $uf)) {
  rename($_FILES['file']['name'],$fn );
  file_put_contents ($fn , $txt, FILE_APPEND );
  echo '<script type="text/javascript">window.parent.location = "index.php";</script>';
}

The upload needs a quick refresh of the webpage (which could be avoided by posting to an hidden iframe and controlling response by an ajax call). The download doesn’t need a refresh:

# note the combined get and post commands
# don't know why this is necessary
$.ajax({
  data: "uuid="+fn,
  type: "post",
  url: "download.php",
  success: function() {
    window.location = 'download.php?uuid='+fn;
  }
});

 

CC-BY-NC Science Surf , accessed 24.08.2026