semvec/pypi-packages huggingface dataset:
py-logs 2.1.2
PyLogs is a easy to use python library to let everyone add logs into their python programs easily.
Requires Python: >=3.5

<p align="center">
  <img width="170" height="170" src="https://raw.githubusercontent.com/kkrypt0nn/PyLogs/master/logo.png">
</p>

# PyLogs
[![Build Status](https://travis-ci.org/kkrypt0nn/PyLogs.svg?branch=master)](https://travis-ci.org/kkrypt0nn/PyLogs) [![Python Versions](https://img.shields.io/badge/python-3.5%20%7C%203.6%20%7C%203.7%20%7C%203.8-orange)](https://pypi.org/project/py-logs)  [![PyPi Versions](https://img.shields.io/badge/release-v2.1.2-blue)](https://pypi.org/project/py-logs) 

PyLogs is a python library made by Krypton so that it is easier for everyone to add logs into their python projects.

## Getting Started
By following the incoming instructions, you will be able to get PyLogs into any of your projects.

### Prerequisites
To be able to use PyLogs you will need:
* Python 3.x
* Python IDE ([PyCharm](https://jetbrains.com/pycharm))

### Installing
* Open your command prompt or terminal and install PyLogs with the following command

For only the current user:
```
pip install --user py-logs
```
For all the computer users:
```
pip install py-logs
```

* To start using PyLogs you need to import `pylogs`

```python
import pylogs

print(pylogs.__name__ + ", Version " + pylogs.__version__)
print("Made by " + pylogs.__author__)
```

* To create new logs you will need to use, for example, the `PyLogs.critical()` method

```python
import pylogs

print(pylogs.__name__ + ", Version " + pylogs.__version__)
print("Made by " + pylogs.__author__ + "\n\n")

# Prints Critical Error Message With Color
pylogs.critical("Critical Error Message", True)
# Prints Critical Error Message Without Color
pylogs.critical("Critical Error Message", False)

# Prints Warning Message With Color
pylogs.warning("Warning Message", True)
# Prints Warning Message Without Color
pylogs.warning("Warning Message", False)
```

If you still do not understand after following these steps, there is an example file called [Example.py](Example.py).

## Built With
* [PyCharm](https://jetbrains.com/pycharm)
* [Python 3.x](https://python.org)

## Contributing
Please read [CONTRIBUTING.md](CONTRIBUTING.md) for details on our code of conduct, and the process for submitting pull requests to this project.

## Bugs & TODOs
The list of known bugs of PyLogs is available [here](BUGS.md).

The TODO list of PyLogs is available [here](TODOS.md).

## Issues
Before submitting any issues, make sure to read the [known bugs](BUGS.md) file.

Submit your issues that you encounter while installing and using PyLogs [here](https://github.com/kkrypt0nn/PyLogs/issues).

## Versioning
We use [SemVer](http://semver.org/) for versioning. For the versions available, see the [tags on this repository](https://github.com/kkrypt0nn/PyLogs/tags).

## Authors
* **Krypton** - *Initial work* - [kkrypt0nn](https://github.com/kkrypt0nn)

## License
This project is licensed under the [Apache 2.0](LICENSE.md) License - see the [LICENSE.md](LICENSE.md) file for details.
h-anomaly 0.0.6
A small example package Anomaly detection using hierarchical clustering, anomaly detector, classifiers and fast model rebuilding

# h_anomaly
A small example package Anomaly detection using hierarchical clustering, anomaly detector, classifiers and fast model rebuilding

## Required Packages to run - 

```
1) pandas
2) numpy
3) pickle
4) scipy
5) freediscovery
6) sklearn
7) matplotlib

```

## Install the Package

```
pip install -U h_anomaly

```

## To Use the Package:

### Import h_anomaly
```
import h_anomaly - 'from h_anomaly import driver'

```
### Building Tree for the 1st time
```
cluster,cluster_tree,max_depth = driver.cluster_driver(file_path,target_class,default_class)

```
### Loading New data for testing
```
df,train_X,train_y = driver.get_data(file_path,target_class,default_class)

```
### Storing Test Data for future uses
```
test_df,test_X,test_y = driver.get_data(file_path,target_class,default_class)
cluster.set_test(test_X,test_y)

```
### Certify Model for performance monitoring:
```
cluster.certify_model(cluster_tree,test_y)

```
### Check Cluster model for retraining
```
cluster.check_model(cluster_tree,threshold)

```

## Available Functions:
```
1) fit - Fit the Data into the Birch algorithm to create the clusters
  def fit(self,data,y)
2) set_test - Store the test data for future uses
  set_test(self,data,y)
3) get_cluster_tree - For each cluster at every level creates the bcluster objects
  get_cluster_tree(self)
4) model_adder - Classification model added to each cluster by this function (Change this function to add different model)
  def model_adder(self,cluster_tree)
5) update_model - Classification model is updated with new data
   update_model(self,cluster_tree,cluster_id)
6) outlier_model_adder - Outlier detection model is added to each cluster (Change this function to add different model)
  outlier_model_adder(self,cluster_tree)
7) certify_model - Scores are calculated in this function
  certify_model(self,cluster_tree,test_y)

```