forked from autogluon/autogluon
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfull_install.sh
More file actions
executable file
·52 lines (46 loc) · 1.47 KB
/
full_install.sh
File metadata and controls
executable file
·52 lines (46 loc) · 1.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
#!/usr/bin/env bash
set -euo pipefail
# Get the directory of the script and always change to it
script_dir=$(dirname "$0")
cd "$script_dir"
# Check if we're in Colab
IN_COLAB=$(python -c "
try:
import google.colab
print('true')
except ImportError:
print('false')
")
# Set installation type based on environment
if [ "$IN_COLAB" == "true" ]; then
EDITABLE="false"
echo "Colab detected - forcing non-editable install"
else
EDITABLE="true"
fi
# Handle user override of editable setting
while test $# -gt 0
do
case "$1" in
--non-editable) EDITABLE="false";;
*) echo "Error: Unused argument: $1" >&2
exit 1;;
esac
shift
done
# Check if uv is installed
if ! python -m pip show uv &> /dev/null; then
echo "uv could not be found. Installing uv..."
python -m pip install uv
fi
# Use uv to install packages
# TODO: We should simplify this by having a single setup.py at project root, and let user call `pip install -e .`
if [ "$EDITABLE" == "true" ]; then
# Editable install (used outside Colab)
python -m uv pip install --refresh -e common/[tests]
python -m uv pip install -e core/[all,tests] -e features/ -e tabular/[all,tests] -e multimodal/[tests] -e timeseries/[all,tests] -e eda/ -e autogluon/
else
# Non-editable install (forced in Colab)
python -m uv pip install --refresh common/[tests]
python -m uv pip install core/[all,tests] features/ tabular/[all,tests] multimodal/[tests] timeseries/[all,tests] eda/ autogluon/
fi