-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
31 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
''' | ||
Package for data anonymization of different data types | ||
such as tabular, text, images and sound. | ||
''' | ||
|
||
__version__ = "0.1.1" | ||
|
||
# Check if all dependencies have been installed | ||
|
||
hard_dependencies = ("faker", "cape_privacy", "pandas", "numpy") | ||
missing_dependencies = [] | ||
|
||
for dependency in hard_dependencies: | ||
try: | ||
__import__(dependency) | ||
except ImportError as e: | ||
missing_dependencies.append(f"{dependency}: {e}") | ||
|
||
if missing_dependencies: | ||
raise ImportError( | ||
"Unable to import required dependencies:\n" + "\n".join(missing_dependencies) | ||
) | ||
del hard_dependencies, dependency, missing_dependencies | ||
|
||
|
||
from anonympy import pandas | ||
from anonympy import images | ||
from anonympy import sound | ||
from anonympy import text | ||
|
||
__all__ = ["pandas", "tabular", "sound", "text"] |