Operation system: Raspbery Pi OS (Debian 10)
QEMU emulator version: 2+
// LICENSE | |
// ======= | |
// Copyright (c) 2017-2019 Advanced Micro Devices, Inc. All rights reserved. | |
// ------- | |
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation | |
// files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, | |
// modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the | |
// Software is furnished to do so, subject to the following conditions: | |
// ------- | |
// The above copyright notice and this permission notice shall be included in all copies or substantial portions of the |
#!/bin/bash | |
#set -e | |
# install-wifi - 03/05/2021 - by MrEngman. | |
UPDATE_SELF=${UPDATE_SELF:-1} | |
UPDATE_URI="http://downloads.fars-robotics.net/wifi-drivers/install-wifi" | |
ROOT_PATH=${ROOT_PATH:-"/"} | |
WORK_PATH=${WORK_PATH:-"${ROOT_PATH}/root"} |
import tensorflow as tf | |
def entmax15(inputs, axis=-1): | |
""" | |
Entmax 1.5 implementation, heavily inspired by | |
* paper: https://arxiv.org/pdf/1905.05702.pdf | |
* pytorch code: https://github.com/deep-spin/entmax | |
:param inputs: similar to softmax logits, but for entmax1.5 | |
:param axis: entmax1.5 outputs will sum to 1 over this axis | |
:return: entmax activations of same shape as inputs |
var assert = require( 'assert' ); | |
function findFrequentBigram( s ) { | |
var i, freqs = {}, topFreq = 0, topPair = null, bigram; | |
for ( i = 0; i < s.length; i += 2 ) { | |
bigram = s.slice( i, i + 2 ); | |
freq = ++freqs[bigram]; |