Since communication over ROS2 across WSL2 border doesn't work out of the box, here's my notes for getting it to work.
Make sure to select cyclonedds RMW on both ends:
(Linux)
export RMW_IMPLEMENTATION=rmw_cyclonedds_cpp
(Windows)
| correct_position(A, B, C, S) :- S = [A, _, _], \+ member(B, S), \+ member(C, S). | |
| correct_position(A, B, C, S) :- S = [_, B, _], \+ member(A, S), \+ member(C, S). | |
| correct_position(A, B, C, S) :- S = [_, _, C], \+ member(A, S), \+ member(B, S). | |
| wrong_position(A, B, C, S) :- (S = [_, A, _] ; S = [_, _, A]), \+ member(B, S), \+ member(C, S). | |
| wrong_position(A, B, C, S) :- (S = [B, _, _] ; S = [_, _, B]), \+ member(A, S), \+ member(C, S). | |
| wrong_position(A, B, C, S) :- (S = [C, _, _] ; S = [_, C, _]), \+ member(A, S), \+ member(B, S). | |
| two_wrong_position(A, B, C, S) :- S \= [A, _, _], S \= [_, B, _], member(A, S), member(B, S), \+ member(C, S). | |
| two_wrong_position(A, B, C, S) :- S \= [A, _, _], S \= [_, _, C], member(A, S), member(C, S), \+ member(B, S). |
| #!/usr/bin/env python3 | |
| market, period = 'XBTEUR', 60 | |
| imgw, imgh = 22, 22 | |
| import krakenex | |
| from pykrakenapi import KrakenAPI | |
| api = krakenex.API() | |
| k = KrakenAPI(api) | |
| ohlc, last = k.get_ohlc_data(market, period) | |
| a = ohlc.to_numpy() | |
| a = a[:imgw,:] |
Since communication over ROS2 across WSL2 border doesn't work out of the box, here's my notes for getting it to work.
Make sure to select cyclonedds RMW on both ends:
(Linux)
export RMW_IMPLEMENTATION=rmw_cyclonedds_cpp
(Windows)
| #include <string> | |
| #include <vector> | |
| #include <map> | |
| #include <cmath> | |
| #include <random> | |
| #include <chrono> | |
| #include <iostream> | |
| #include <Eigen/Geometry> |