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 hidden or 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 tradingview_ta import TA_Handler, Interval | |
| import requests | |
| import timeout_decorator | |
| @timeout_decorator.timeout(300) | |
| def tvta(): | |
| symbols = ["BTCUSDT", "ETHUSDT", "SOLUSDT", "BCHUSDT"] | |
| for sym in symbols: | |
| handler = TA_Handler(symbol=sym, screener='crypto', exchange='BINANCEUS', interval=Interval.INTERVAL_1_DAY) |
This file contains hidden or 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 hashlib | |
| from starlette.applications import Starlette | |
| from starlette.requests import Request | |
| from starlette.responses import PlainTextResponse | |
| from starlette.routing import Route | |
| async def online_sha256(stream) -> bytes: | |
| hasher = hashlib.sha256() |
This file contains hidden or 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
| use pyo3::prelude::*; | |
| #[pyclass] | |
| #[derive(Debug, Clone, PartialEq)] | |
| enum AttachmentType { | |
| Image, | |
| Video, | |
| Audio, | |
| File, | |
| } |
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 hidden or 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
| #include <X11/Xlib.h> | |
| int main() { | |
| XEvent event; | |
| Display* display = XOpenDisplay(NULL); | |
| Window w = XCreateSimpleWindow(display, DefaultRootWindow(display), 50, 50, 250, 250, 1, BlackPixel(display, 0), WhitePixel(display, 0)); | |
| XMapWindow(display, w); | |
| XSelectInput(display, w, ExposureMask); | |
| for (;;) { |
This file contains hidden or 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
| config.version=6 | |
| global.use_flock=false | |
| profile1.qt.last_path=/root | |
| profile1.qt.places.SortColumn=1 | |
| profile1.qt.places.SortOrder=0 | |
| profile1.qt.settingsdialog.exclude.SortColumn=1 | |
| profile1.qt.settingsdialog.exclude.SortOrder=0 | |
| profile1.qt.settingsdialog.include.SortColumn=1 | |
| profile1.qt.settingsdialog.include.SortOrder=0 | |
| profile1.schedule.custom_time=8,12,18,23 |
This file contains hidden or 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
| config.version=6 | |
| global.use_flock=false | |
| profile1.qt.last_path=/root | |
| profile1.qt.places.SortColumn=1 | |
| profile1.qt.places.SortOrder=0 | |
| profile1.qt.settingsdialog.exclude.SortColumn=1 | |
| profile1.qt.settingsdialog.exclude.SortOrder=0 | |
| profile1.qt.settingsdialog.include.SortColumn=1 | |
| profile1.qt.settingsdialog.include.SortOrder=0 | |
| profile1.schedule.custom_time=8,12,18,23 |
This file contains hidden or 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 gymnasium as gym | |
| import numpy as np | |
| from gymnasium.envs.mujoco.mujoco_env import MujocoEnv | |
| # Env initialization | |
| env = gym.make("Swimmer-v4", render_mode="human") | |
| # Wrap to have reward statistics | |
| env = gym.wrappers.RecordEpisodeStatistics(env) | |
| mujoco_env = env.unwrapped | |
| n_joints = 2 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.