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 os | |
| import sys | |
| import re | |
| import typer | |
| import requests | |
| from dotenv import load_dotenv | |
| from tqdm import tqdm | |
| from typing import Optional | |
| load_dotenv() |
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 <stdio.h> | |
| #include <stdlib.h> | |
| #include <math.h> | |
| #include <time.h> | |
| // Sigmoid activation function | |
| double sigmoid(double x) { | |
| return 1.0 / (1.0 + exp(-x)); | |
| } |
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 dataclasses import asdict as _to_dict, fields, is_dataclass | |
| from typing import Any, Dict, Mapping, Type, TypeVar | |
| T = TypeVar("T", bound="DictMixin") | |
| U = TypeVar("U") | |
| def _from_dict(cls: Type[U], src: Mapping[str, Any]) -> U: | |
| field_types_lookup = {field.name: field.type for field in fields(cls)} |