<%*
let weekNumber = moment().format('W')
let year = moment().format('Y')
let month = tp.date.now("MM-MMMM")
let yesterday = tp.date.now("YYYY-MM-DD_ddd", -1)
let today = tp.date.now("YYYY-MM-DD_ddd")
let tag = "#cw" + weekNumber + "_" + year
let prevTag = #cw${weekNumber - 1}_${year}
let file_path = A_daily_notes/${year}/${month}/${today}
%>
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
def upload_time_in_days(mbps, tb): | |
mbps_in_MBps = mbps / 8 | |
tb_in_MB = tb * 1000000 | |
total_seconds = tb_in_MB / mbps_in_MBps | |
total_days = total_seconds / (60 * 60 * 24) | |
return total_days |
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 --platform=linux/amd64 ubuntu:22.04 | |
ENV DEBIAN_FRONTEND=noninteractive | |
RUN apt-get update && \ | |
apt-get install -y curl unzip wget zsh \ | |
libopenblas-dev \ | |
libjpeg-dev \ | |
libpng-dev \ | |
build-essential \ |
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
# Wait for the transform to become available | |
listener.waitForTransform('/base_link', '/end_effector', rospy.Time(), rospy.Duration(4.0)) | |
# Get the transformation matrix from the robot base to the end effector | |
(trans, rot) = listener.lookupTransform('/base_link', '/end_effector', rospy.Time(0)) | |
rot_matrix = tf.transformations.quaternion_matrix(rot) | |
transformation_matrix = tf.transformations.concatenate_matrices(rot_matrix, tf.transformations.translation_matrix(trans)) |
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
import rospy | |
import tf | |
from geometry_msgs.msg import Quaternion | |
# Create a quaternion object | |
quat = Quaternion() | |
quat.x = 0.1 | |
quat.y = 0.2 | |
quat.z = 0.3 | |
quat.w = 0.4 |
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
#!/usr/bin/env python | |
import rospy | |
import cv2 | |
from sensor_msgs.msg import Image | |
from cv_bridge import CvBridge | |
from PyCapture2 import * | |
def image_publisher(): | |
rospy.init_node('epiphan_image_publisher', anonymous=True) | |
pub = rospy.Publisher('image_topic', Image, queue_size=10) |
- The system is inherently distributed (e.g. mobile devices like smartphones)
- Reliability (some nodes can fail and the system keeps functioning; fault tolerance)
- Performance (process data faster by utilizing multiple nodes or achieve better latency by requesting data from a nearby node)
- The capacity of a single machine isn’t enough for the task (e.g. limited memory size, bandwidth, CPU cycles, etc.; scalability)
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
""" | |
Copy all images that look similar to a template to a different location. | |
This script finds similar areas in source images, crops the target area, and | |
stores the result in a target directory. | |
""" | |
import concurrent.futures | |
import cv2 | |
import os | |
import multiprocessing |
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
""" | |
Splits a dataset of png images into train, val, and test sets. | |
Creates the folders and randomly chooses files. | |
""" | |
import os | |
import random | |
import argparse | |
try: | |
import termcolor |
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
alias bb='brave-browser' | |
alias t='tmux' | |
alias ta='tmux attach' | |
alias sagi='sudo apt-get install -y' | |
alias sagu='sudo apt-get update' | |
alias e='echo' | |
alias sl='exa' | |
#alias ls='exa' | |
alias sls='exa' | |
alias pwd='pwd -P' |
NewerOlder