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 glue.config import importer, settings | |
from glue.core import Data | |
from glue.core import DataCollection | |
from qtpy import QtGui | |
from qtpy.QtWidgets import QWidget, QInputDialog, QLineEdit | |
import numpy as np | |
# TODO: write a test code |
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 fasttext | |
import mlflow.pyfunc | |
class FastTextWrapper(mlflow.pyfunc.PythonModel): | |
""" | |
Class to train and use FastText Models | |
""" | |
def load_context(self, context): |
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 airflow import DAG | |
from airflow.operators.python import PythonOperator, PythonVirtualenvOperator, BranchPythonOperator | |
from airflow.operators.bash import BashOperator | |
from datetime import datetime | |
def choose_stock(ti): | |
data = ti.xcom_pull(task_ids="download_yf") | |
spy_data = data['Close']['SPY'] |
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
# Repo: MySpace/TemplateRepo | |
# File: azure-pipeline.yml | |
name: cicd_ci | |
trigger: | |
branches: | |
include: | |
- master |
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
# Repo: MySpace/TemplateRepo | |
# File: ci_template.yml | |
jobs: | |
- job: | |
displayName: yamllint_checks | |
pool: | |
vmImage: 'ubuntu-latest' | |
steps: | |
- script: | |
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
# Repo: MySpace/UserRepo | |
# File: azure-pipeline2.yml | |
name: cicd_ci | |
trigger: | |
branches: | |
include: | |
- master |
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
# Repo: MySpace/UserRepo | |
# File: azure-pipeline3.yml | |
name: cicd_ci | |
trigger: | |
branches: | |
include: | |
- master |
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
# Repo: MySpace/TemplateRepo | |
# File: ci_template.yml | |
parameters: | |
- name: pylint_threshold | |
type: string | |
default: 8.0 | |
- name: lint_folder | |
type: string | |
default: "mockcase-on-test" |
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
# Repo: MySpace/UserRepo | |
# File: azure-pipeline3.yml | |
name: cicd_ci | |
variables: | |
- name: PylintThreshold | |
value: 8.0 | |
- name: LintFolder | |
value: "folder_dir" |
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 fasttext | |
import mlflow | |
from .fast_text_wrapper import FastTextWrapper | |
def save_model( | |
df: pd.DataFrame, | |
model_name: str = "model_name", | |
corpus_filename: str = "prepared_corpus", | |
prepared_content: str = "prepared_text", | |
): |
OlderNewer