This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
########################### ASE CONFIG START ########################### | |
# Setup for pool PC (optional if you work on your own PC) | |
# Tested with Xubuntu 16.04 and ROS Kinetic | |
# Global ROS environment | |
source /opt/ros/kinetic/setup.bash | |
# Workspace realted ROS environment | |
source /media/localdisk/data/$(whoami)/catkin_ws/devel/setup.bash |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# example: /usr/bin/parallel-ssh -i -h ~/.pssh_hosts_files -l tkorthals -A "wget -O - .../build_ase.sh > /tmp/build_ase.sh; bash /tmp/build_ase.sh" | |
set -e | |
source /opt/ros/kinetic/setup.bash | |
F="/media/localdisk/data/$(whoami)" | |
C="${F}/catkin_ws" | |
S="${C}/src" | |
A="${S}/ase_exercises" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
touch ppo_evaluate.txt | |
echo 'Flat: ' >> ppo_evaluate.txt | |
cp /root/ros2learn/environments/gym-gazebo2/gym_gazebo2/worlds/empty_bullet.world /root/ros2learn/environments/gym-gazebo2/gym_gazebo2/worlds/parcour.world | |
python3 run_evaluation_ppo2.py | |
cat ppoTestRun.txt >> ppo_evaluate.txt | |
pkill gzserver |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Prerequisties install: | |
- sudo apt-get install build-essential checkinstall | |
These are the dependancies required by python: | |
- sudo apt-get install libbz2-dev libc6-dev libgdbm-dev libncursesw5-dev libreadline-gplv2-dev libssl-dev libsqlite3-dev tk-dev | |
Download the tar source file from python.org (at the time of writing 3.6.1 is the latest release): | |
- wget -O ~/Downloads/python3.6.1.tgz https://www.python.org/ftp/python/3.6.1/Python-3.6.1.tgz | |
Via command line navigate to the downloaded file directory: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'''Example of VAE on MNIST dataset using MLP | |
tf-2.0 adaptation of the keras implementation [1] | |
with additional output of the reconstruction | |
and KL losses as discussed in [2] | |
# Reference | |
[1] https://github.com/keras-team/keras/blob/master/examples/variational_autoencoder.py | |
[2] https://stackoverflow.com/q/54069363/2084944 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from scipy.spatial.transform import Rotation as R | |
import numpy as np | |
#Example of having to rotations in different coordinate systems (r&q), where we want to reporesent r inside q: | |
#r0, r1, r2, r3, r4, ..., rX (i.e. BRIX quaternionen) | |
#q0, q1, q2, q3, q4, ..., qX (i.e. Vive quaternionen) | |
# | |
#delta = q0.inv() * r0 | |
#delta1 = r0.inv() * r1 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<sdf version='1.4'> | |
<world name='default'> | |
<!-- include sun and ground plane --> | |
<include><uri>model://sun</uri></include> | |
<include><uri>model://ground_plane</uri></include> | |
<model name="sensor_box"> | |
<static>true</static> | |
<link name="link"> | |
<pose>0 0 0.251 0 0 0</pose> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Based on chromium, add the following 2 lines to `sudo crontab -e` | |
# 1 1 * * * rm /tmp/.org.chromium.Chromium.* | |
# 1 1 * * * rm -r /tmp/scoped_dir* | |
# Start a display (https://en.wikipedia.org/wiki/Xvfb) | |
export DISPLAY=:1 | |
Xvfb :1 -screen 0 1024x768x16 & | |
PIDD=$! | |
# Get links | |
wget -O - https://www.stackoverflow.com | grep -oe "\"\/questions\/[[:digit:]]*\/[[:alnum:]-]*\"" | tr -d '"' | sed '1~2d' | sed "s#^#www\.stackoverflow.com#g" | head -n5 > so_questions.txt |
NewerOlder