FeatureEnVi: Visual Analytics for Feature Engineering Using Stepwise Selection and Semi-Automatic Extraction Approaches
https://doi.org/10.1109/TVCG.2022.3141040
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
47 lines
1.2 KiB
47 lines
1.2 KiB
4 years ago
|
"""Xonsh activate script for virtualenv"""
|
||
|
from xonsh.tools import get_sep as _get_sep
|
||
|
|
||
|
def _deactivate(args):
|
||
|
if "pydoc" in aliases:
|
||
|
del aliases["pydoc"]
|
||
|
|
||
|
if ${...}.get("_OLD_VIRTUAL_PATH", ""):
|
||
|
$PATH = $_OLD_VIRTUAL_PATH
|
||
|
del $_OLD_VIRTUAL_PATH
|
||
|
|
||
|
if ${...}.get("_OLD_VIRTUAL_PYTHONHOME", ""):
|
||
|
$PYTHONHOME = $_OLD_VIRTUAL_PYTHONHOME
|
||
|
del $_OLD_VIRTUAL_PYTHONHOME
|
||
|
|
||
|
if "VIRTUAL_ENV" in ${...}:
|
||
|
del $VIRTUAL_ENV
|
||
|
|
||
|
if "VIRTUAL_ENV_PROMPT" in ${...}:
|
||
|
del $VIRTUAL_ENV_PROMPT
|
||
|
|
||
|
if "nondestructive" not in args:
|
||
|
# Self destruct!
|
||
|
del aliases["deactivate"]
|
||
|
|
||
|
|
||
|
# unset irrelevant variables
|
||
|
_deactivate(["nondestructive"])
|
||
|
aliases["deactivate"] = _deactivate
|
||
|
|
||
|
$VIRTUAL_ENV = r"/Users/anchaa/Documents/Research/iStacking_code/istacking/backend/venv"
|
||
|
|
||
|
$_OLD_VIRTUAL_PATH = $PATH
|
||
|
$PATH = $PATH[:]
|
||
|
$PATH.add($VIRTUAL_ENV + _get_sep() + "bin", front=True, replace=True)
|
||
|
|
||
|
if ${...}.get("PYTHONHOME", ""):
|
||
|
# unset PYTHONHOME if set
|
||
|
$_OLD_VIRTUAL_PYTHONHOME = $PYTHONHOME
|
||
|
del $PYTHONHOME
|
||
|
|
||
|
$VIRTUAL_ENV_PROMPT = ""
|
||
|
if not $VIRTUAL_ENV_PROMPT:
|
||
|
del $VIRTUAL_ENV_PROMPT
|
||
|
|
||
|
aliases["pydoc"] = ["python", "-m", "pydoc"]
|