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/sh | |
# Check fisrt parameter and run python script with it | |
if [ "$1" = "ui" ]; then | |
streamlit run ui.py | |
elif [ "$1" = "api" ]; then | |
python3 api.py | |
else | |
echo "Invalid run type, please use 'ui' or 'api'." | |
fi |
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
def timeout_decorator(timeout): | |
def decorator(func): | |
@wraps(func) | |
def wrapper(*args, **kwargs): | |
result_queue = multiprocessing.Queue() | |
def target_func(queue, *args, **kwargs): | |
try: | |
result = func(*args, **kwargs) | |
queue.put(result) |
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
# Thnaks to SeaseLtd/vector-search-elastic-tutorial | |
import elasticsearch | |
from pathlib import Path | |
from eland.ml.pytorch import PyTorchModel | |
from eland.ml.pytorch.transformers import TransformerModel | |
# Elastic configuration. | |
ELASTIC_ADDRESS = "http://localhost:9200" | |
# Uncomment the following lines if start ES with SECURITY ENABLED. | |
#ELASTIC_ADDRESS = "https://localhost:9200" |
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
# It's created by Serkan UYSAL; github:uysalserkan | |
# Set up git variables | |
autoload -Uz vcs_info | |
zstyle ':vcs_info:*' check-for-changes true | |
zstyle ':vcs_info:*' unstagedstr '%F{red}*' | |
zstyle ':vcs_info:*' stagedstr '%F{yellow}+' | |
zstyle ':vcs_info:*' actionformats '%F{5}[%F{2}%b%F{3}|%F{1}%a%c%u%F{5}]%f ' | |
zstyle ':vcs_info:*' formats '%F{5}[%F{2}%b%c%u%F{5}]%f ' | |
zstyle ':vcs_info:svn:*' branchformat '%b' |
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
"better-comments.tags": [ | |
{ | |
"tag": "ERROR", | |
"color": "#FF0000", | |
"strikethrough": false, | |
"underline": false, | |
"backgroundColor": "transparent", | |
"bold": false, | |
"italic": false | |
}, |
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
spring.mail.host=smtp.gmail.com | |
spring.mail.port=587 | |
spring.mail.username=username | |
spring.mail.password=password | |
# Other properties | |
spring.mail.properties.mail.smtp.auth=true | |
spring.mail.properties.mail.smtp.connectiontimeout=5000 | |
spring.mail.properties.mail.smtp.timeout=5000 | |
spring.mail.properties.mail.smtp.writetimeout=5000 |
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
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver | |
spring.datasource.username=admin | |
spring.datasource.password=my_amazing_passwordz | |
spring.datasource.url=jdbc:mysql://localhost:3306/employee_mng | |
spring.jpa.hibernate.ddl-auto=update |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE hibernate-configuration PUBLIC "-//Hibernate/Hibernate Configuration DTD 3.0//EN" "http://hibernate.org/dtd/hibernate-configuration-3.0.dtd"> | |
<hibernate-configuration> | |
<session-factory> | |
<property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property> | |
<property name="hibernate.connection.url">jdbc:mysql://localhost:3306/java_relation</property> | |
<property name="hibernate.connection.username">admin</property> | |
<property name="hibernate.connection.password">myPasswordExactlySame</property> | |
<!-- <property name="hibernate.connection.pool_size">1</property> | |
<property name="hibernate.current_session_context_class">thread</property> |
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
/** | |
* @file SudokuSolver.cpp | |
* @author Serkan UYSAL (uysalserkan08) | |
* @brief Sudoku Solver with recursive functions and class. | |
* @version 0.1 | |
* @date 2021-06-12 | |
* | |
* @copyright Copyright (c) 2021 | |
* | |
*/ |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
NewerOlder