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
// Copyright 2023 Boris Shishov (github: @bshishov) | |
// | |
// 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 Software. |
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 time | |
import subprocess | |
import json | |
from contextlib import contextmanager | |
MYSTEM_BINARY = 'mystem.exe' | |
MYSTEM_ARGS = '--input-format json --fixlist fixlist.txt --format json -gi -d -c' | |
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 typing import List, Set, Dict, NamedTuple | |
import multiprocessing | |
import random | |
class Book(NamedTuple): | |
id: int | |
score: int | |
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
Shader "Custom/SimpleDecal" | |
{ | |
Properties { | |
_MainTex ("Main Texture", 2D) = "white" {} | |
[HDR]_Color ("Color", Color) = (1, 1, 1, 1) | |
} | |
SubShader | |
{ | |
Tags { "RenderType"= "Transparent" "Queue" = "Transparent" } | |
Pass |
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 numpy as np | |
EPSILON = 1e-10 | |
def _error(actual: np.ndarray, predicted: np.ndarray): | |
""" Simple error """ | |
return actual - predicted | |
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 numpy as np | |
from typing import List, Tuple | |
from alpha_chess_zero import settings | |
from alpha_chess_zero.game_model import GameModel | |
class MCTSNode(object): | |
def __init__(self, state): | |
self.state = state |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
import time | |
import matplotlib.pyplot as plt | |
import wave | |
import numpy as np | |
# Mapping for numpy arrays | |
types = {1: np.int8, 2: np.int16, 4: np.int32} | |
# Open the wave file |
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
#!/bin/bash | |
WIKI_URL=___ # with trailing slash | |
WIKI_USERNAME=___ | |
WIKI_PASSWORD=___ | |
WIKI_DUMP_DIR=./dump | |
WIKI_DUMP_DIR_LOGIN=${WIKI_DUMP_DIR}/login | |
WIKI_LOGIN_PAGE="index.php?title=Служебная:Вход" | |
#WIKI_START_PAGE="index.php?title=Содержание" | |
WIKI_START_PAGE="index.php/Содержание" |