Upload folder using huggingface_hub
Browse files- assets/Fascetta/LIBERO_S_next_to_the_ramekin/norm_stats.json +84 -0
- assets/Fascetta/on_the_stove/norm_stats.json +84 -0
- assets/siamaky1984/libero_object_no_noops/norm_stats.json +84 -0
- config.json +7 -0
- examples/libero/.venv/.gitignore +1 -0
- examples/libero/.venv/.lock +0 -0
- examples/libero/.venv/CACHEDIR.TAG +1 -0
- examples/libero/.venv/bin/activate +130 -0
- examples/libero/.venv/bin/activate.bat +71 -0
- examples/libero/.venv/bin/activate.csh +76 -0
- examples/libero/.venv/bin/activate.fish +124 -0
- examples/libero/.venv/bin/activate.nu +102 -0
- examples/libero/.venv/bin/activate.ps1 +82 -0
- examples/libero/.venv/bin/activate_this.py +59 -0
- examples/libero/.venv/bin/deactivate.bat +39 -0
- examples/libero/.venv/bin/pydoc.bat +22 -0
- examples/libero/.venv/lib/python3.8/site-packages/_virtualenv.pth +3 -0
- examples/libero/.venv/lib/python3.8/site-packages/_virtualenv.py +101 -0
- examples/libero/.venv/pyvenv.cfg +5 -0
- model.safetensors +3 -0
assets/Fascetta/LIBERO_S_next_to_the_ramekin/norm_stats.json
ADDED
|
@@ -0,0 +1,84 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"norm_stats": {
|
| 3 |
+
"state": {
|
| 4 |
+
"mean": [
|
| 5 |
+
-0.0946599543094635,
|
| 6 |
+
0.2633593678474426,
|
| 7 |
+
1.0392905473709106,
|
| 8 |
+
3.0468411445617676,
|
| 9 |
+
-0.18272967636585236,
|
| 10 |
+
0.2060517817735672,
|
| 11 |
+
0.021636808291077614,
|
| 12 |
+
-0.02177802473306656
|
| 13 |
+
],
|
| 14 |
+
"std": [
|
| 15 |
+
0.1110076904296875,
|
| 16 |
+
0.09492177516222,
|
| 17 |
+
0.09377224743366241,
|
| 18 |
+
0.09936493635177612,
|
| 19 |
+
0.2586742043495178,
|
| 20 |
+
0.1934213489294052,
|
| 21 |
+
0.017457883805036545,
|
| 22 |
+
0.01709621027112007
|
| 23 |
+
],
|
| 24 |
+
"q01": [
|
| 25 |
+
-0.2176899008229375,
|
| 26 |
+
0.0030046426530927414,
|
| 27 |
+
0.9138178078174591,
|
| 28 |
+
2.7895496290206907,
|
| 29 |
+
-0.8678844391584396,
|
| 30 |
+
-0.13294741432964802,
|
| 31 |
+
0.0016243882952025161,
|
| 32 |
+
-0.039877144283396775
|
| 33 |
+
],
|
| 34 |
+
"q99": [
|
| 35 |
+
0.10242307487577196,
|
| 36 |
+
0.3793273600183427,
|
| 37 |
+
1.1933960454702377,
|
| 38 |
+
3.2052713788986207,
|
| 39 |
+
0.25292687714099893,
|
| 40 |
+
0.6670205700725317,
|
| 41 |
+
0.03994362685373053,
|
| 42 |
+
-0.0018800945966067906
|
| 43 |
+
]
|
| 44 |
+
},
|
| 45 |
+
"actions": {
|
| 46 |
+
"mean": [
|
| 47 |
+
0.15861409902572632,
|
| 48 |
+
0.13132956624031067,
|
| 49 |
+
-0.12897998094558716,
|
| 50 |
+
-0.009427698329091072,
|
| 51 |
+
-0.014121240936219692,
|
| 52 |
+
-0.017616380006074905,
|
| 53 |
+
0.00390625
|
| 54 |
+
],
|
| 55 |
+
"std": [
|
| 56 |
+
0.3563438057899475,
|
| 57 |
+
0.4030913710594177,
|
| 58 |
+
0.5065368413925171,
|
| 59 |
+
0.03480944037437439,
|
| 60 |
+
0.07369058579206467,
|
| 61 |
+
0.042605701833963394,
|
| 62 |
+
0.9999923706054688
|
| 63 |
+
],
|
| 64 |
+
"q01": [
|
| 65 |
+
-0.5545510774135589,
|
| 66 |
+
-0.6028998135209084,
|
| 67 |
+
-0.9375,
|
| 68 |
+
-0.09861278352141381,
|
| 69 |
+
-0.19732800176143644,
|
| 70 |
+
-0.13930843088924885,
|
| 71 |
+
-1.0
|
| 72 |
+
],
|
| 73 |
+
"q99": [
|
| 74 |
+
0.9371603571414946,
|
| 75 |
+
0.8623890892148016,
|
| 76 |
+
0.937125,
|
| 77 |
+
0.10387114691734314,
|
| 78 |
+
0.17987141847610477,
|
| 79 |
+
0.07379871468842031,
|
| 80 |
+
0.9996
|
| 81 |
+
]
|
| 82 |
+
}
|
| 83 |
+
}
|
| 84 |
+
}
|
assets/Fascetta/on_the_stove/norm_stats.json
ADDED
|
@@ -0,0 +1,84 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"norm_stats": {
|
| 3 |
+
"state": {
|
| 4 |
+
"mean": [
|
| 5 |
+
-0.12361854314804077,
|
| 6 |
+
0.04007770121097565,
|
| 7 |
+
1.032537579536438,
|
| 8 |
+
3.0763304233551025,
|
| 9 |
+
-0.11540324985980988,
|
| 10 |
+
-0.1299287974834442,
|
| 11 |
+
0.01479234267026186,
|
| 12 |
+
-0.01666111685335636
|
| 13 |
+
],
|
| 14 |
+
"std": [
|
| 15 |
+
0.13693147897720337,
|
| 16 |
+
0.1370949000120163,
|
| 17 |
+
0.07904954999685287,
|
| 18 |
+
0.06008042395114899,
|
| 19 |
+
0.19050845503807068,
|
| 20 |
+
0.17192292213439941,
|
| 21 |
+
0.01595493033528328,
|
| 22 |
+
0.01567769981920719
|
| 23 |
+
],
|
| 24 |
+
"q01": [
|
| 25 |
+
-0.29904447215795515,
|
| 26 |
+
-0.13288118991851808,
|
| 27 |
+
0.926817469227314,
|
| 28 |
+
2.9167179470062257,
|
| 29 |
+
-0.74424846637249,
|
| 30 |
+
-0.5272024286985397,
|
| 31 |
+
0.0009964433826506137,
|
| 32 |
+
-0.04038033561646007
|
| 33 |
+
],
|
| 34 |
+
"q99": [
|
| 35 |
+
0.09891178522109989,
|
| 36 |
+
0.25425332989692684,
|
| 37 |
+
1.1792743253231048,
|
| 38 |
+
3.1868851218223573,
|
| 39 |
+
0.214086361002922,
|
| 40 |
+
0.3296789348006248,
|
| 41 |
+
0.03968827028386295,
|
| 42 |
+
-0.0021465617535868647
|
| 43 |
+
]
|
| 44 |
+
},
|
| 45 |
+
"actions": {
|
| 46 |
+
"mean": [
|
| 47 |
+
0.15303023159503937,
|
| 48 |
+
0.12373506277799606,
|
| 49 |
+
-0.15597423911094666,
|
| 50 |
+
0.002140609547495842,
|
| 51 |
+
0.0022221142426133156,
|
| 52 |
+
-0.021091081202030182,
|
| 53 |
+
0.4000411629676819
|
| 54 |
+
],
|
| 55 |
+
"std": [
|
| 56 |
+
0.3653120994567871,
|
| 57 |
+
0.33585062623023987,
|
| 58 |
+
0.43746432662010193,
|
| 59 |
+
0.02901223674416542,
|
| 60 |
+
0.06820792704820633,
|
| 61 |
+
0.04201524332165718,
|
| 62 |
+
0.9164971709251404
|
| 63 |
+
],
|
| 64 |
+
"q01": [
|
| 65 |
+
-0.5413285846710205,
|
| 66 |
+
-0.5628,
|
| 67 |
+
-0.9375,
|
| 68 |
+
-0.06973821546137332,
|
| 69 |
+
-0.1727177255153656,
|
| 70 |
+
-0.143779289278388,
|
| 71 |
+
-1.0
|
| 72 |
+
],
|
| 73 |
+
"q99": [
|
| 74 |
+
0.8241916061282157,
|
| 75 |
+
0.7097999999999998,
|
| 76 |
+
0.7470000000000001,
|
| 77 |
+
0.0963242175847292,
|
| 78 |
+
0.1947419943213463,
|
| 79 |
+
0.07806213857829569,
|
| 80 |
+
0.9996
|
| 81 |
+
]
|
| 82 |
+
}
|
| 83 |
+
}
|
| 84 |
+
}
|
assets/siamaky1984/libero_object_no_noops/norm_stats.json
ADDED
|
@@ -0,0 +1,84 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"norm_stats": {
|
| 3 |
+
"state": {
|
| 4 |
+
"mean": [
|
| 5 |
+
-0.02999422512948513,
|
| 6 |
+
-0.007977200672030449,
|
| 7 |
+
0.20292827486991882,
|
| 8 |
+
3.108609676361084,
|
| 9 |
+
-0.2140609174966812,
|
| 10 |
+
-0.1130998432636261,
|
| 11 |
+
0.029379429295659065,
|
| 12 |
+
-0.03055577725172043
|
| 13 |
+
],
|
| 14 |
+
"std": [
|
| 15 |
+
0.06695207953453064,
|
| 16 |
+
0.17607420682907104,
|
| 17 |
+
0.07807384431362152,
|
| 18 |
+
0.08673282712697983,
|
| 19 |
+
0.33542343974113464,
|
| 20 |
+
0.20727868378162384,
|
| 21 |
+
0.009565925225615501,
|
| 22 |
+
0.009197734296321869
|
| 23 |
+
],
|
| 24 |
+
"q01": [
|
| 25 |
+
-0.1492735779225826,
|
| 26 |
+
-0.2599771349191666,
|
| 27 |
+
0.009789850303158164,
|
| 28 |
+
2.754254650211334,
|
| 29 |
+
-1.4010699427127837,
|
| 30 |
+
-0.6869121198415756,
|
| 31 |
+
0.008187016749859322,
|
| 32 |
+
-0.04016836693586083
|
| 33 |
+
],
|
| 34 |
+
"q99": [
|
| 35 |
+
0.09055517340302466,
|
| 36 |
+
0.29054851372241963,
|
| 37 |
+
0.337063336356543,
|
| 38 |
+
3.2608008350372315,
|
| 39 |
+
0.31974816913604753,
|
| 40 |
+
0.40351211075782767,
|
| 41 |
+
0.03988814650826389,
|
| 42 |
+
-0.009117137690016534
|
| 43 |
+
]
|
| 44 |
+
},
|
| 45 |
+
"actions": {
|
| 46 |
+
"mean": [
|
| 47 |
+
0.0634874701499939,
|
| 48 |
+
0.14189772307872772,
|
| 49 |
+
-0.04346214607357979,
|
| 50 |
+
0.0013831917895004153,
|
| 51 |
+
0.006612811237573624,
|
| 52 |
+
-0.015147515572607517,
|
| 53 |
+
0.07168233394622803
|
| 54 |
+
],
|
| 55 |
+
"std": [
|
| 56 |
+
0.26457372307777405,
|
| 57 |
+
0.4325467646121979,
|
| 58 |
+
0.44876566529273987,
|
| 59 |
+
0.024345658719539642,
|
| 60 |
+
0.04974175617098808,
|
| 61 |
+
0.04224759712815285,
|
| 62 |
+
0.9974275231361389
|
| 63 |
+
],
|
| 64 |
+
"q01": [
|
| 65 |
+
-0.5385857349872589,
|
| 66 |
+
-0.8760300009727477,
|
| 67 |
+
-0.9375,
|
| 68 |
+
-0.06967607759833336,
|
| 69 |
+
-0.11685171356201171,
|
| 70 |
+
-0.1597105631828308,
|
| 71 |
+
-1.0
|
| 72 |
+
],
|
| 73 |
+
"q99": [
|
| 74 |
+
0.8435142843961716,
|
| 75 |
+
0.8429346146821977,
|
| 76 |
+
0.937125,
|
| 77 |
+
0.08136427915096284,
|
| 78 |
+
0.15096685872077942,
|
| 79 |
+
0.0867214322090149,
|
| 80 |
+
0.9996
|
| 81 |
+
]
|
| 82 |
+
}
|
| 83 |
+
}
|
| 84 |
+
}
|
config.json
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"action_dim": 32,
|
| 3 |
+
"action_horizon": 15,
|
| 4 |
+
"paligemma_variant": "gemma_2b",
|
| 5 |
+
"action_expert_variant": "gemma_300m",
|
| 6 |
+
"precision": "bfloat16"
|
| 7 |
+
}
|
examples/libero/.venv/.gitignore
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
*
|
examples/libero/.venv/.lock
ADDED
|
File without changes
|
examples/libero/.venv/CACHEDIR.TAG
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
Signature: 8a477f597d28d172789f06886806bc55
|
examples/libero/.venv/bin/activate
ADDED
|
@@ -0,0 +1,130 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Copyright (c) 2020-202x The virtualenv developers
|
| 2 |
+
#
|
| 3 |
+
# Permission is hereby granted, free of charge, to any person obtaining
|
| 4 |
+
# a copy of this software and associated documentation files (the
|
| 5 |
+
# "Software"), to deal in the Software without restriction, including
|
| 6 |
+
# without limitation the rights to use, copy, modify, merge, publish,
|
| 7 |
+
# distribute, sublicense, and/or sell copies of the Software, and to
|
| 8 |
+
# permit persons to whom the Software is furnished to do so, subject to
|
| 9 |
+
# the following conditions:
|
| 10 |
+
#
|
| 11 |
+
# The above copyright notice and this permission notice shall be
|
| 12 |
+
# included in all copies or substantial portions of the Software.
|
| 13 |
+
#
|
| 14 |
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
| 15 |
+
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
| 16 |
+
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
| 17 |
+
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
| 18 |
+
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
| 19 |
+
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
| 20 |
+
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
| 21 |
+
|
| 22 |
+
# This file must be used with "source bin/activate" *from bash*
|
| 23 |
+
# you cannot run it directly
|
| 24 |
+
|
| 25 |
+
if ! [ -z "${SCRIPT_PATH+_}" ] ; then
|
| 26 |
+
_OLD_SCRIPT_PATH="$SCRIPT_PATH"
|
| 27 |
+
fi
|
| 28 |
+
|
| 29 |
+
# Get script path (only used if environment is relocatable).
|
| 30 |
+
if [ -n "${BASH_VERSION:+x}" ] ; then
|
| 31 |
+
SCRIPT_PATH="${BASH_SOURCE[0]}"
|
| 32 |
+
if [ "$SCRIPT_PATH" = "$0" ]; then
|
| 33 |
+
# Only bash has a reasonably robust check for source'dness.
|
| 34 |
+
echo "You must source this script: \$ source $0" >&2
|
| 35 |
+
exit 33
|
| 36 |
+
fi
|
| 37 |
+
elif [ -n "${ZSH_VERSION:+x}" ] ; then
|
| 38 |
+
SCRIPT_PATH="${(%):-%x}"
|
| 39 |
+
elif [ -n "${KSH_VERSION:+x}" ] ; then
|
| 40 |
+
SCRIPT_PATH="${.sh.file}"
|
| 41 |
+
fi
|
| 42 |
+
|
| 43 |
+
deactivate () {
|
| 44 |
+
unset -f pydoc >/dev/null 2>&1 || true
|
| 45 |
+
|
| 46 |
+
# reset old environment variables
|
| 47 |
+
# ! [ -z ${VAR+_} ] returns true if VAR is declared at all
|
| 48 |
+
if ! [ -z "${_OLD_VIRTUAL_PATH:+_}" ] ; then
|
| 49 |
+
PATH="$_OLD_VIRTUAL_PATH"
|
| 50 |
+
export PATH
|
| 51 |
+
unset _OLD_VIRTUAL_PATH
|
| 52 |
+
fi
|
| 53 |
+
if ! [ -z "${_OLD_VIRTUAL_PYTHONHOME+_}" ] ; then
|
| 54 |
+
PYTHONHOME="$_OLD_VIRTUAL_PYTHONHOME"
|
| 55 |
+
export PYTHONHOME
|
| 56 |
+
unset _OLD_VIRTUAL_PYTHONHOME
|
| 57 |
+
fi
|
| 58 |
+
|
| 59 |
+
# The hash command must be called to get it to forget past
|
| 60 |
+
# commands. Without forgetting past commands the $PATH changes
|
| 61 |
+
# we made may not be respected
|
| 62 |
+
hash -r 2>/dev/null
|
| 63 |
+
|
| 64 |
+
if ! [ -z "${_OLD_VIRTUAL_PS1+_}" ] ; then
|
| 65 |
+
PS1="$_OLD_VIRTUAL_PS1"
|
| 66 |
+
export PS1
|
| 67 |
+
unset _OLD_VIRTUAL_PS1
|
| 68 |
+
fi
|
| 69 |
+
|
| 70 |
+
unset VIRTUAL_ENV
|
| 71 |
+
unset VIRTUAL_ENV_PROMPT
|
| 72 |
+
if [ ! "${1-}" = "nondestructive" ] ; then
|
| 73 |
+
# Self destruct!
|
| 74 |
+
unset -f deactivate
|
| 75 |
+
fi
|
| 76 |
+
}
|
| 77 |
+
|
| 78 |
+
# unset irrelevant variables
|
| 79 |
+
deactivate nondestructive
|
| 80 |
+
|
| 81 |
+
VIRTUAL_ENV='/media/pinas/Chris/models/pi0.5/examples/libero/.venv'
|
| 82 |
+
if ([ "$OSTYPE" = "cygwin" ] || [ "$OSTYPE" = "msys" ]) && $(command -v cygpath &> /dev/null) ; then
|
| 83 |
+
VIRTUAL_ENV=$(cygpath -u "$VIRTUAL_ENV")
|
| 84 |
+
fi
|
| 85 |
+
export VIRTUAL_ENV
|
| 86 |
+
|
| 87 |
+
# Unset the `SCRIPT_PATH` variable, now that the `VIRTUAL_ENV` variable
|
| 88 |
+
# has been set. This is important for relocatable environments.
|
| 89 |
+
if ! [ -z "${_OLD_SCRIPT_PATH+_}" ] ; then
|
| 90 |
+
SCRIPT_PATH="$_OLD_SCRIPT_PATH"
|
| 91 |
+
export SCRIPT_PATH
|
| 92 |
+
unset _OLD_SCRIPT_PATH
|
| 93 |
+
else
|
| 94 |
+
unset SCRIPT_PATH
|
| 95 |
+
fi
|
| 96 |
+
|
| 97 |
+
_OLD_VIRTUAL_PATH="$PATH"
|
| 98 |
+
PATH="$VIRTUAL_ENV/bin:$PATH"
|
| 99 |
+
export PATH
|
| 100 |
+
|
| 101 |
+
if [ "x" != x ] ; then
|
| 102 |
+
VIRTUAL_ENV_PROMPT=""
|
| 103 |
+
else
|
| 104 |
+
VIRTUAL_ENV_PROMPT=$(basename "$VIRTUAL_ENV")
|
| 105 |
+
fi
|
| 106 |
+
export VIRTUAL_ENV_PROMPT
|
| 107 |
+
|
| 108 |
+
# unset PYTHONHOME if set
|
| 109 |
+
if ! [ -z "${PYTHONHOME+_}" ] ; then
|
| 110 |
+
_OLD_VIRTUAL_PYTHONHOME="$PYTHONHOME"
|
| 111 |
+
unset PYTHONHOME
|
| 112 |
+
fi
|
| 113 |
+
|
| 114 |
+
if [ -z "${VIRTUAL_ENV_DISABLE_PROMPT-}" ] ; then
|
| 115 |
+
_OLD_VIRTUAL_PS1="${PS1-}"
|
| 116 |
+
PS1="(${VIRTUAL_ENV_PROMPT}) ${PS1-}"
|
| 117 |
+
export PS1
|
| 118 |
+
fi
|
| 119 |
+
|
| 120 |
+
# Make sure to unalias pydoc if it's already there
|
| 121 |
+
alias pydoc 2>/dev/null >/dev/null && unalias pydoc || true
|
| 122 |
+
|
| 123 |
+
pydoc () {
|
| 124 |
+
python -m pydoc "$@"
|
| 125 |
+
}
|
| 126 |
+
|
| 127 |
+
# The hash command must be called to get it to forget past
|
| 128 |
+
# commands. Without forgetting past commands the $PATH changes
|
| 129 |
+
# we made may not be respected
|
| 130 |
+
hash -r 2>/dev/null || true
|
examples/libero/.venv/bin/activate.bat
ADDED
|
@@ -0,0 +1,71 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
@REM Copyright (c) 2020-202x The virtualenv developers
|
| 2 |
+
@REM
|
| 3 |
+
@REM Permission is hereby granted, free of charge, to any person obtaining
|
| 4 |
+
@REM a copy of this software and associated documentation files (the
|
| 5 |
+
@REM "Software"), to deal in the Software without restriction, including
|
| 6 |
+
@REM without limitation the rights to use, copy, modify, merge, publish,
|
| 7 |
+
@REM distribute, sublicense, and/or sell copies of the Software, and to
|
| 8 |
+
@REM permit persons to whom the Software is furnished to do so, subject to
|
| 9 |
+
@REM the following conditions:
|
| 10 |
+
@REM
|
| 11 |
+
@REM The above copyright notice and this permission notice shall be
|
| 12 |
+
@REM included in all copies or substantial portions of the Software.
|
| 13 |
+
@REM
|
| 14 |
+
@REM THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
| 15 |
+
@REM EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
| 16 |
+
@REM MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
| 17 |
+
@REM NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
| 18 |
+
@REM LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
| 19 |
+
@REM OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
| 20 |
+
@REM WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
| 21 |
+
|
| 22 |
+
@REM This file is UTF-8 encoded, so we need to update the current code page while executing it
|
| 23 |
+
@for /f "tokens=2 delims=:." %%a in ('"%SystemRoot%\System32\chcp.com"') do @set _OLD_CODEPAGE=%%a
|
| 24 |
+
|
| 25 |
+
@if defined _OLD_CODEPAGE (
|
| 26 |
+
"%SystemRoot%\System32\chcp.com" 65001 > nul
|
| 27 |
+
)
|
| 28 |
+
|
| 29 |
+
@for %%i in ("/media/pinas/Chris/models/pi0.5/examples/libero/.venv") do @set "VIRTUAL_ENV=%%~fi"
|
| 30 |
+
|
| 31 |
+
@set "VIRTUAL_ENV_PROMPT="
|
| 32 |
+
@if NOT DEFINED VIRTUAL_ENV_PROMPT (
|
| 33 |
+
@for %%d in ("%VIRTUAL_ENV%") do @set "VIRTUAL_ENV_PROMPT=%%~nxd"
|
| 34 |
+
)
|
| 35 |
+
|
| 36 |
+
@if defined _OLD_VIRTUAL_PROMPT (
|
| 37 |
+
@set "PROMPT=%_OLD_VIRTUAL_PROMPT%"
|
| 38 |
+
) else (
|
| 39 |
+
@if not defined PROMPT (
|
| 40 |
+
@set "PROMPT=$P$G"
|
| 41 |
+
)
|
| 42 |
+
@if not defined VIRTUAL_ENV_DISABLE_PROMPT (
|
| 43 |
+
@set "_OLD_VIRTUAL_PROMPT=%PROMPT%"
|
| 44 |
+
)
|
| 45 |
+
)
|
| 46 |
+
@if not defined VIRTUAL_ENV_DISABLE_PROMPT (
|
| 47 |
+
@set "PROMPT=(%VIRTUAL_ENV_PROMPT%) %PROMPT%"
|
| 48 |
+
)
|
| 49 |
+
|
| 50 |
+
@REM Don't use () to avoid problems with them in %PATH%
|
| 51 |
+
@if defined _OLD_VIRTUAL_PYTHONHOME @goto ENDIFVHOME
|
| 52 |
+
@set "_OLD_VIRTUAL_PYTHONHOME=%PYTHONHOME%"
|
| 53 |
+
:ENDIFVHOME
|
| 54 |
+
|
| 55 |
+
@set PYTHONHOME=
|
| 56 |
+
|
| 57 |
+
@REM if defined _OLD_VIRTUAL_PATH (
|
| 58 |
+
@if not defined _OLD_VIRTUAL_PATH @goto ENDIFVPATH1
|
| 59 |
+
@set "PATH=%_OLD_VIRTUAL_PATH%"
|
| 60 |
+
:ENDIFVPATH1
|
| 61 |
+
@REM ) else (
|
| 62 |
+
@if defined _OLD_VIRTUAL_PATH @goto ENDIFVPATH2
|
| 63 |
+
@set "_OLD_VIRTUAL_PATH=%PATH%"
|
| 64 |
+
:ENDIFVPATH2
|
| 65 |
+
|
| 66 |
+
@set "PATH=%VIRTUAL_ENV%\bin;%PATH%"
|
| 67 |
+
|
| 68 |
+
@if defined _OLD_CODEPAGE (
|
| 69 |
+
"%SystemRoot%\System32\chcp.com" %_OLD_CODEPAGE% > nul
|
| 70 |
+
@set _OLD_CODEPAGE=
|
| 71 |
+
)
|
examples/libero/.venv/bin/activate.csh
ADDED
|
@@ -0,0 +1,76 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Copyright (c) 2020-202x The virtualenv developers
|
| 2 |
+
#
|
| 3 |
+
# Permission is hereby granted, free of charge, to any person obtaining
|
| 4 |
+
# a copy of this software and associated documentation files (the
|
| 5 |
+
# "Software"), to deal in the Software without restriction, including
|
| 6 |
+
# without limitation the rights to use, copy, modify, merge, publish,
|
| 7 |
+
# distribute, sublicense, and/or sell copies of the Software, and to
|
| 8 |
+
# permit persons to whom the Software is furnished to do so, subject to
|
| 9 |
+
# the following conditions:
|
| 10 |
+
#
|
| 11 |
+
# The above copyright notice and this permission notice shall be
|
| 12 |
+
# included in all copies or substantial portions of the Software.
|
| 13 |
+
#
|
| 14 |
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
| 15 |
+
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
| 16 |
+
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
| 17 |
+
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
| 18 |
+
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
| 19 |
+
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
| 20 |
+
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
| 21 |
+
|
| 22 |
+
# This file must be used with "source bin/activate.csh" *from csh*.
|
| 23 |
+
# You cannot run it directly.
|
| 24 |
+
# Created by Davide Di Blasi <davidedb@gmail.com>.
|
| 25 |
+
|
| 26 |
+
set newline='\
|
| 27 |
+
'
|
| 28 |
+
|
| 29 |
+
alias deactivate 'test $?_OLD_VIRTUAL_PATH != 0 && setenv PATH "$_OLD_VIRTUAL_PATH:q" && unset _OLD_VIRTUAL_PATH; rehash; test $?_OLD_VIRTUAL_PROMPT != 0 && set prompt="$_OLD_VIRTUAL_PROMPT:q" && unset _OLD_VIRTUAL_PROMPT; unsetenv VIRTUAL_ENV; unsetenv VIRTUAL_ENV_PROMPT; test "\!:*" != "nondestructive" && unalias deactivate && unalias pydoc'
|
| 30 |
+
|
| 31 |
+
# Unset irrelevant variables.
|
| 32 |
+
deactivate nondestructive
|
| 33 |
+
|
| 34 |
+
setenv VIRTUAL_ENV '/media/pinas/Chris/models/pi0.5/examples/libero/.venv'
|
| 35 |
+
|
| 36 |
+
set _OLD_VIRTUAL_PATH="$PATH:q"
|
| 37 |
+
setenv PATH "$VIRTUAL_ENV:q/bin:$PATH:q"
|
| 38 |
+
|
| 39 |
+
|
| 40 |
+
|
| 41 |
+
if ('' != "") then
|
| 42 |
+
setenv VIRTUAL_ENV_PROMPT ''
|
| 43 |
+
else
|
| 44 |
+
setenv VIRTUAL_ENV_PROMPT "$VIRTUAL_ENV:t:q"
|
| 45 |
+
endif
|
| 46 |
+
|
| 47 |
+
if ( $?VIRTUAL_ENV_DISABLE_PROMPT ) then
|
| 48 |
+
if ( $VIRTUAL_ENV_DISABLE_PROMPT == "" ) then
|
| 49 |
+
set do_prompt = "1"
|
| 50 |
+
else
|
| 51 |
+
set do_prompt = "0"
|
| 52 |
+
endif
|
| 53 |
+
else
|
| 54 |
+
set do_prompt = "1"
|
| 55 |
+
endif
|
| 56 |
+
|
| 57 |
+
if ( $do_prompt == "1" ) then
|
| 58 |
+
# Could be in a non-interactive environment,
|
| 59 |
+
# in which case, $prompt is undefined and we wouldn't
|
| 60 |
+
# care about the prompt anyway.
|
| 61 |
+
if ( $?prompt ) then
|
| 62 |
+
set _OLD_VIRTUAL_PROMPT="$prompt:q"
|
| 63 |
+
if ( "$prompt:q" =~ *"$newline:q"* ) then
|
| 64 |
+
:
|
| 65 |
+
else
|
| 66 |
+
set prompt = '('"$VIRTUAL_ENV_PROMPT:q"') '"$prompt:q"
|
| 67 |
+
endif
|
| 68 |
+
endif
|
| 69 |
+
endif
|
| 70 |
+
|
| 71 |
+
unset env_name
|
| 72 |
+
unset do_prompt
|
| 73 |
+
|
| 74 |
+
alias pydoc python -m pydoc
|
| 75 |
+
|
| 76 |
+
rehash
|
examples/libero/.venv/bin/activate.fish
ADDED
|
@@ -0,0 +1,124 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Copyright (c) 2020-202x The virtualenv developers
|
| 2 |
+
#
|
| 3 |
+
# Permission is hereby granted, free of charge, to any person obtaining
|
| 4 |
+
# a copy of this software and associated documentation files (the
|
| 5 |
+
# "Software"), to deal in the Software without restriction, including
|
| 6 |
+
# without limitation the rights to use, copy, modify, merge, publish,
|
| 7 |
+
# distribute, sublicense, and/or sell copies of the Software, and to
|
| 8 |
+
# permit persons to whom the Software is furnished to do so, subject to
|
| 9 |
+
# the following conditions:
|
| 10 |
+
#
|
| 11 |
+
# The above copyright notice and this permission notice shall be
|
| 12 |
+
# included in all copies or substantial portions of the Software.
|
| 13 |
+
#
|
| 14 |
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
| 15 |
+
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
| 16 |
+
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
| 17 |
+
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
| 18 |
+
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
| 19 |
+
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
| 20 |
+
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
| 21 |
+
|
| 22 |
+
# This file must be used using `source bin/activate.fish` *within a running fish ( http://fishshell.com ) session*.
|
| 23 |
+
# Do not run it directly.
|
| 24 |
+
|
| 25 |
+
function _bashify_path -d "Converts a fish path to something bash can recognize"
|
| 26 |
+
set fishy_path $argv
|
| 27 |
+
set bashy_path $fishy_path[1]
|
| 28 |
+
for path_part in $fishy_path[2..-1]
|
| 29 |
+
set bashy_path "$bashy_path:$path_part"
|
| 30 |
+
end
|
| 31 |
+
echo $bashy_path
|
| 32 |
+
end
|
| 33 |
+
|
| 34 |
+
function _fishify_path -d "Converts a bash path to something fish can recognize"
|
| 35 |
+
echo $argv | tr ':' '\n'
|
| 36 |
+
end
|
| 37 |
+
|
| 38 |
+
function deactivate -d 'Exit virtualenv mode and return to the normal environment.'
|
| 39 |
+
# reset old environment variables
|
| 40 |
+
if test -n "$_OLD_VIRTUAL_PATH"
|
| 41 |
+
# https://github.com/fish-shell/fish-shell/issues/436 altered PATH handling
|
| 42 |
+
if test (string sub -s 1 -l 1 $FISH_VERSION) -lt 3
|
| 43 |
+
set -gx PATH (_fishify_path "$_OLD_VIRTUAL_PATH")
|
| 44 |
+
else
|
| 45 |
+
set -gx PATH $_OLD_VIRTUAL_PATH
|
| 46 |
+
end
|
| 47 |
+
set -e _OLD_VIRTUAL_PATH
|
| 48 |
+
end
|
| 49 |
+
|
| 50 |
+
if test -n "$_OLD_VIRTUAL_PYTHONHOME"
|
| 51 |
+
set -gx PYTHONHOME "$_OLD_VIRTUAL_PYTHONHOME"
|
| 52 |
+
set -e _OLD_VIRTUAL_PYTHONHOME
|
| 53 |
+
end
|
| 54 |
+
|
| 55 |
+
if test -n "$_OLD_FISH_PROMPT_OVERRIDE"
|
| 56 |
+
and functions -q _old_fish_prompt
|
| 57 |
+
# Set an empty local `$fish_function_path` to allow the removal of `fish_prompt` using `functions -e`.
|
| 58 |
+
set -l fish_function_path
|
| 59 |
+
|
| 60 |
+
# Erase virtualenv's `fish_prompt` and restore the original.
|
| 61 |
+
functions -e fish_prompt
|
| 62 |
+
functions -c _old_fish_prompt fish_prompt
|
| 63 |
+
functions -e _old_fish_prompt
|
| 64 |
+
set -e _OLD_FISH_PROMPT_OVERRIDE
|
| 65 |
+
end
|
| 66 |
+
|
| 67 |
+
set -e VIRTUAL_ENV
|
| 68 |
+
set -e VIRTUAL_ENV_PROMPT
|
| 69 |
+
|
| 70 |
+
if test "$argv[1]" != 'nondestructive'
|
| 71 |
+
# Self-destruct!
|
| 72 |
+
functions -e pydoc
|
| 73 |
+
functions -e deactivate
|
| 74 |
+
functions -e _bashify_path
|
| 75 |
+
functions -e _fishify_path
|
| 76 |
+
end
|
| 77 |
+
end
|
| 78 |
+
|
| 79 |
+
# Unset irrelevant variables.
|
| 80 |
+
deactivate nondestructive
|
| 81 |
+
|
| 82 |
+
set -gx VIRTUAL_ENV '/media/pinas/Chris/models/pi0.5/examples/libero/.venv'
|
| 83 |
+
|
| 84 |
+
# https://github.com/fish-shell/fish-shell/issues/436 altered PATH handling
|
| 85 |
+
if test (string sub -s 1 -l 1 $FISH_VERSION) -lt 3
|
| 86 |
+
set -gx _OLD_VIRTUAL_PATH (_bashify_path $PATH)
|
| 87 |
+
else
|
| 88 |
+
set -gx _OLD_VIRTUAL_PATH $PATH
|
| 89 |
+
end
|
| 90 |
+
set -gx PATH "$VIRTUAL_ENV"'/bin' $PATH
|
| 91 |
+
|
| 92 |
+
# Prompt override provided?
|
| 93 |
+
# If not, just use the environment name.
|
| 94 |
+
if test -n ''
|
| 95 |
+
set -gx VIRTUAL_ENV_PROMPT ''
|
| 96 |
+
else
|
| 97 |
+
set -gx VIRTUAL_ENV_PROMPT (basename "$VIRTUAL_ENV")
|
| 98 |
+
end
|
| 99 |
+
|
| 100 |
+
# Unset `$PYTHONHOME` if set.
|
| 101 |
+
if set -q PYTHONHOME
|
| 102 |
+
set -gx _OLD_VIRTUAL_PYTHONHOME $PYTHONHOME
|
| 103 |
+
set -e PYTHONHOME
|
| 104 |
+
end
|
| 105 |
+
|
| 106 |
+
function pydoc
|
| 107 |
+
python -m pydoc $argv
|
| 108 |
+
end
|
| 109 |
+
|
| 110 |
+
if test -z "$VIRTUAL_ENV_DISABLE_PROMPT"
|
| 111 |
+
# Copy the current `fish_prompt` function as `_old_fish_prompt`.
|
| 112 |
+
functions -c fish_prompt _old_fish_prompt
|
| 113 |
+
|
| 114 |
+
function fish_prompt
|
| 115 |
+
# Run the user's prompt first; it might depend on (pipe)status.
|
| 116 |
+
set -l prompt (_old_fish_prompt)
|
| 117 |
+
|
| 118 |
+
printf '(%s) ' $VIRTUAL_ENV_PROMPT
|
| 119 |
+
|
| 120 |
+
string join -- \n $prompt # handle multi-line prompts
|
| 121 |
+
end
|
| 122 |
+
|
| 123 |
+
set -gx _OLD_FISH_PROMPT_OVERRIDE "$VIRTUAL_ENV"
|
| 124 |
+
end
|
examples/libero/.venv/bin/activate.nu
ADDED
|
@@ -0,0 +1,102 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Copyright (c) 2020-202x The virtualenv developers
|
| 2 |
+
#
|
| 3 |
+
# Permission is hereby granted, free of charge, to any person obtaining
|
| 4 |
+
# a copy of this software and associated documentation files (the
|
| 5 |
+
# "Software"), to deal in the Software without restriction, including
|
| 6 |
+
# without limitation the rights to use, copy, modify, merge, publish,
|
| 7 |
+
# distribute, sublicense, and/or sell copies of the Software, and to
|
| 8 |
+
# permit persons to whom the Software is furnished to do so, subject to
|
| 9 |
+
# the following conditions:
|
| 10 |
+
#
|
| 11 |
+
# The above copyright notice and this permission notice shall be
|
| 12 |
+
# included in all copies or substantial portions of the Software.
|
| 13 |
+
#
|
| 14 |
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
| 15 |
+
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
| 16 |
+
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
| 17 |
+
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
| 18 |
+
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
| 19 |
+
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
| 20 |
+
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
| 21 |
+
|
| 22 |
+
# virtualenv activation module:
|
| 23 |
+
# - Activate with `overlay use activate.nu`
|
| 24 |
+
# - Deactivate with `deactivate`, as usual
|
| 25 |
+
#
|
| 26 |
+
# To customize the overlay name, you can call `overlay use activate.nu as foo`, but then simply `deactivate` won't work
|
| 27 |
+
# because it is just an alias to hide the "activate" overlay. You'd need to call `overlay hide foo` manually.
|
| 28 |
+
|
| 29 |
+
module warning {
|
| 30 |
+
export-env {
|
| 31 |
+
const file = path self
|
| 32 |
+
error make -u {
|
| 33 |
+
msg: $"`($file | path basename)` is meant to be used with `overlay use`, not `source`"
|
| 34 |
+
}
|
| 35 |
+
}
|
| 36 |
+
|
| 37 |
+
}
|
| 38 |
+
|
| 39 |
+
use warning
|
| 40 |
+
|
| 41 |
+
export-env {
|
| 42 |
+
|
| 43 |
+
let nu_ver = (version | get version | split row '.' | take 2 | each { into int })
|
| 44 |
+
if $nu_ver.0 == 0 and $nu_ver.1 < 106 {
|
| 45 |
+
error make {
|
| 46 |
+
msg: 'virtualenv Nushell activation requires Nushell 0.106 or greater.'
|
| 47 |
+
}
|
| 48 |
+
}
|
| 49 |
+
|
| 50 |
+
def is-string [x] {
|
| 51 |
+
($x | describe) == 'string'
|
| 52 |
+
}
|
| 53 |
+
|
| 54 |
+
def has-env [...names] {
|
| 55 |
+
$names | each {|n| $n in $env } | all {|i| $i }
|
| 56 |
+
}
|
| 57 |
+
|
| 58 |
+
def is-env-true [name: string] {
|
| 59 |
+
if (has-env $name) {
|
| 60 |
+
let val = ($env | get --optional $name)
|
| 61 |
+
if ($val | describe) == 'bool' {
|
| 62 |
+
$val
|
| 63 |
+
} else {
|
| 64 |
+
not ($val | is-empty)
|
| 65 |
+
}
|
| 66 |
+
} else {
|
| 67 |
+
false
|
| 68 |
+
}
|
| 69 |
+
}
|
| 70 |
+
|
| 71 |
+
let virtual_env = '/media/pinas/Chris/models/pi0.5/examples/libero/.venv'
|
| 72 |
+
let bin = 'bin'
|
| 73 |
+
let path_name = if (has-env 'Path') { 'Path' } else { 'PATH' }
|
| 74 |
+
let venv_path = ([$virtual_env $bin] | path join)
|
| 75 |
+
let new_path = ($env | get $path_name | prepend $venv_path)
|
| 76 |
+
let virtual_env_prompt = if ('' | is-empty) {
|
| 77 |
+
($virtual_env | path basename)
|
| 78 |
+
} else {
|
| 79 |
+
''
|
| 80 |
+
}
|
| 81 |
+
let new_env = { $path_name: $new_path VIRTUAL_ENV: $virtual_env VIRTUAL_ENV_PROMPT: $virtual_env_prompt }
|
| 82 |
+
let old_prompt_command = if (has-env 'PROMPT_COMMAND') { $env.PROMPT_COMMAND } else { '' }
|
| 83 |
+
let new_env = if (is-env-true 'VIRTUAL_ENV_DISABLE_PROMPT') {
|
| 84 |
+
$new_env
|
| 85 |
+
} else {
|
| 86 |
+
let virtual_prefix = $'(char lparen)($virtual_env_prompt)(char rparen) '
|
| 87 |
+
let new_prompt = if (has-env 'PROMPT_COMMAND') {
|
| 88 |
+
if ('closure' in ($old_prompt_command | describe)) {
|
| 89 |
+
{|| $'($virtual_prefix)(do $old_prompt_command)' }
|
| 90 |
+
} else {
|
| 91 |
+
{|| $'($virtual_prefix)($old_prompt_command)' }
|
| 92 |
+
}
|
| 93 |
+
} else {
|
| 94 |
+
{|| $'($virtual_prefix)' }
|
| 95 |
+
}
|
| 96 |
+
$new_env | merge { PROMPT_COMMAND: $new_prompt VIRTUAL_PREFIX: $virtual_prefix }
|
| 97 |
+
}
|
| 98 |
+
load-env $new_env
|
| 99 |
+
}
|
| 100 |
+
|
| 101 |
+
export alias pydoc = python -m pydoc
|
| 102 |
+
export alias deactivate = overlay hide activate
|
examples/libero/.venv/bin/activate.ps1
ADDED
|
@@ -0,0 +1,82 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Copyright (c) 2020-202x The virtualenv developers
|
| 2 |
+
#
|
| 3 |
+
# Permission is hereby granted, free of charge, to any person obtaining
|
| 4 |
+
# a copy of this software and associated documentation files (the
|
| 5 |
+
# "Software"), to deal in the Software without restriction, including
|
| 6 |
+
# without limitation the rights to use, copy, modify, merge, publish,
|
| 7 |
+
# distribute, sublicense, and/or sell copies of the Software, and to
|
| 8 |
+
# permit persons to whom the Software is furnished to do so, subject to
|
| 9 |
+
# the following conditions:
|
| 10 |
+
#
|
| 11 |
+
# The above copyright notice and this permission notice shall be
|
| 12 |
+
# included in all copies or substantial portions of the Software.
|
| 13 |
+
#
|
| 14 |
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
| 15 |
+
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
| 16 |
+
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
| 17 |
+
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
| 18 |
+
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
| 19 |
+
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
| 20 |
+
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
| 21 |
+
|
| 22 |
+
$script:THIS_PATH = $myinvocation.mycommand.path
|
| 23 |
+
$script:BASE_DIR = Split-Path (Resolve-Path "$THIS_PATH/..") -Parent
|
| 24 |
+
|
| 25 |
+
function global:deactivate([switch] $NonDestructive) {
|
| 26 |
+
if (Test-Path variable:_OLD_VIRTUAL_PATH) {
|
| 27 |
+
$env:PATH = $variable:_OLD_VIRTUAL_PATH
|
| 28 |
+
Remove-Variable "_OLD_VIRTUAL_PATH" -Scope global
|
| 29 |
+
}
|
| 30 |
+
|
| 31 |
+
if (Test-Path function:_old_virtual_prompt) {
|
| 32 |
+
$function:prompt = $function:_old_virtual_prompt
|
| 33 |
+
Remove-Item function:\_old_virtual_prompt
|
| 34 |
+
}
|
| 35 |
+
|
| 36 |
+
if ($env:VIRTUAL_ENV) {
|
| 37 |
+
Remove-Item env:VIRTUAL_ENV -ErrorAction SilentlyContinue
|
| 38 |
+
}
|
| 39 |
+
|
| 40 |
+
if ($env:VIRTUAL_ENV_PROMPT) {
|
| 41 |
+
Remove-Item env:VIRTUAL_ENV_PROMPT -ErrorAction SilentlyContinue
|
| 42 |
+
}
|
| 43 |
+
|
| 44 |
+
if (!$NonDestructive) {
|
| 45 |
+
# Self destruct!
|
| 46 |
+
Remove-Item function:deactivate
|
| 47 |
+
Remove-Item function:pydoc
|
| 48 |
+
}
|
| 49 |
+
}
|
| 50 |
+
|
| 51 |
+
function global:pydoc {
|
| 52 |
+
python -m pydoc $args
|
| 53 |
+
}
|
| 54 |
+
|
| 55 |
+
# unset irrelevant variables
|
| 56 |
+
deactivate -nondestructive
|
| 57 |
+
|
| 58 |
+
$VIRTUAL_ENV = $BASE_DIR
|
| 59 |
+
$env:VIRTUAL_ENV = $VIRTUAL_ENV
|
| 60 |
+
|
| 61 |
+
if ("" -ne "") {
|
| 62 |
+
$env:VIRTUAL_ENV_PROMPT = ""
|
| 63 |
+
}
|
| 64 |
+
else {
|
| 65 |
+
$env:VIRTUAL_ENV_PROMPT = $( Split-Path $env:VIRTUAL_ENV -Leaf )
|
| 66 |
+
}
|
| 67 |
+
|
| 68 |
+
New-Variable -Scope global -Name _OLD_VIRTUAL_PATH -Value $env:PATH
|
| 69 |
+
|
| 70 |
+
$env:PATH = "$env:VIRTUAL_ENV/bin:" + $env:PATH
|
| 71 |
+
if (!$env:VIRTUAL_ENV_DISABLE_PROMPT) {
|
| 72 |
+
function global:_old_virtual_prompt {
|
| 73 |
+
""
|
| 74 |
+
}
|
| 75 |
+
$function:_old_virtual_prompt = $function:prompt
|
| 76 |
+
|
| 77 |
+
function global:prompt {
|
| 78 |
+
# Add the custom prefix to the existing prompt
|
| 79 |
+
$previous_prompt_value = & $function:_old_virtual_prompt
|
| 80 |
+
("(" + $env:VIRTUAL_ENV_PROMPT + ") " + $previous_prompt_value)
|
| 81 |
+
}
|
| 82 |
+
}
|
examples/libero/.venv/bin/activate_this.py
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Copyright (c) 2020-202x The virtualenv developers
|
| 2 |
+
#
|
| 3 |
+
# Permission is hereby granted, free of charge, to any person obtaining
|
| 4 |
+
# a copy of this software and associated documentation files (the
|
| 5 |
+
# "Software"), to deal in the Software without restriction, including
|
| 6 |
+
# without limitation the rights to use, copy, modify, merge, publish,
|
| 7 |
+
# distribute, sublicense, and/or sell copies of the Software, and to
|
| 8 |
+
# permit persons to whom the Software is furnished to do so, subject to
|
| 9 |
+
# the following conditions:
|
| 10 |
+
#
|
| 11 |
+
# The above copyright notice and this permission notice shall be
|
| 12 |
+
# included in all copies or substantial portions of the Software.
|
| 13 |
+
#
|
| 14 |
+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
| 15 |
+
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
| 16 |
+
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
| 17 |
+
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
| 18 |
+
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
| 19 |
+
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
| 20 |
+
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
| 21 |
+
|
| 22 |
+
"""
|
| 23 |
+
Activate virtualenv for current interpreter:
|
| 24 |
+
|
| 25 |
+
import runpy
|
| 26 |
+
runpy.run_path(this_file)
|
| 27 |
+
|
| 28 |
+
This can be used when you must use an existing Python interpreter, not the virtualenv bin/python.
|
| 29 |
+
""" # noqa: D415
|
| 30 |
+
|
| 31 |
+
from __future__ import annotations
|
| 32 |
+
|
| 33 |
+
import os
|
| 34 |
+
import site
|
| 35 |
+
import sys
|
| 36 |
+
|
| 37 |
+
try:
|
| 38 |
+
abs_file = os.path.abspath(__file__)
|
| 39 |
+
except NameError as exc:
|
| 40 |
+
msg = "You must use import runpy; runpy.run_path(this_file)"
|
| 41 |
+
raise AssertionError(msg) from exc
|
| 42 |
+
|
| 43 |
+
bin_dir = os.path.dirname(abs_file)
|
| 44 |
+
base = bin_dir[: -len("bin") - 1] # strip away the bin part from the __file__, plus the path separator
|
| 45 |
+
|
| 46 |
+
# prepend bin to PATH (this file is inside the bin directory)
|
| 47 |
+
os.environ["PATH"] = os.pathsep.join([bin_dir, *os.environ.get("PATH", "").split(os.pathsep)])
|
| 48 |
+
os.environ["VIRTUAL_ENV"] = base # virtual env is right above bin directory
|
| 49 |
+
os.environ["VIRTUAL_ENV_PROMPT"] = "" or os.path.basename(base) # noqa: SIM222
|
| 50 |
+
|
| 51 |
+
# add the virtual environments libraries to the host python import mechanism
|
| 52 |
+
prev_length = len(sys.path)
|
| 53 |
+
for lib in "../lib/python3.8/site-packages".split(os.pathsep):
|
| 54 |
+
path = os.path.realpath(os.path.join(bin_dir, lib))
|
| 55 |
+
site.addsitedir(path)
|
| 56 |
+
sys.path[:] = sys.path[prev_length:] + sys.path[0:prev_length]
|
| 57 |
+
|
| 58 |
+
sys.real_prefix = sys.prefix
|
| 59 |
+
sys.prefix = base
|
examples/libero/.venv/bin/deactivate.bat
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
@REM Copyright (c) 2020-202x The virtualenv developers
|
| 2 |
+
@REM
|
| 3 |
+
@REM Permission is hereby granted, free of charge, to any person obtaining
|
| 4 |
+
@REM a copy of this software and associated documentation files (the
|
| 5 |
+
@REM "Software"), to deal in the Software without restriction, including
|
| 6 |
+
@REM without limitation the rights to use, copy, modify, merge, publish,
|
| 7 |
+
@REM distribute, sublicense, and/or sell copies of the Software, and to
|
| 8 |
+
@REM permit persons to whom the Software is furnished to do so, subject to
|
| 9 |
+
@REM the following conditions:
|
| 10 |
+
@REM
|
| 11 |
+
@REM The above copyright notice and this permission notice shall be
|
| 12 |
+
@REM included in all copies or substantial portions of the Software.
|
| 13 |
+
@REM
|
| 14 |
+
@REM THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
| 15 |
+
@REM EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
| 16 |
+
@REM MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
| 17 |
+
@REM NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
| 18 |
+
@REM LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
| 19 |
+
@REM OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
| 20 |
+
@REM WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
| 21 |
+
|
| 22 |
+
@set VIRTUAL_ENV=
|
| 23 |
+
@set VIRTUAL_ENV_PROMPT=
|
| 24 |
+
|
| 25 |
+
@REM Don't use () to avoid problems with them in %PATH%
|
| 26 |
+
@if not defined _OLD_VIRTUAL_PROMPT @goto ENDIFVPROMPT
|
| 27 |
+
@set "PROMPT=%_OLD_VIRTUAL_PROMPT%"
|
| 28 |
+
@set _OLD_VIRTUAL_PROMPT=
|
| 29 |
+
:ENDIFVPROMPT
|
| 30 |
+
|
| 31 |
+
@if not defined _OLD_VIRTUAL_PYTHONHOME @goto ENDIFVHOME
|
| 32 |
+
@set "PYTHONHOME=%_OLD_VIRTUAL_PYTHONHOME%"
|
| 33 |
+
@set _OLD_VIRTUAL_PYTHONHOME=
|
| 34 |
+
:ENDIFVHOME
|
| 35 |
+
|
| 36 |
+
@if not defined _OLD_VIRTUAL_PATH @goto ENDIFVPATH
|
| 37 |
+
@set "PATH=%_OLD_VIRTUAL_PATH%"
|
| 38 |
+
@set _OLD_VIRTUAL_PATH=
|
| 39 |
+
:ENDIFVPATH
|
examples/libero/.venv/bin/pydoc.bat
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
@REM Copyright (c) 2020-202x The virtualenv developers
|
| 2 |
+
@REM
|
| 3 |
+
@REM Permission is hereby granted, free of charge, to any person obtaining
|
| 4 |
+
@REM a copy of this software and associated documentation files (the
|
| 5 |
+
@REM "Software"), to deal in the Software without restriction, including
|
| 6 |
+
@REM without limitation the rights to use, copy, modify, merge, publish,
|
| 7 |
+
@REM distribute, sublicense, and/or sell copies of the Software, and to
|
| 8 |
+
@REM permit persons to whom the Software is furnished to do so, subject to
|
| 9 |
+
@REM the following conditions:
|
| 10 |
+
@REM
|
| 11 |
+
@REM The above copyright notice and this permission notice shall be
|
| 12 |
+
@REM included in all copies or substantial portions of the Software.
|
| 13 |
+
@REM
|
| 14 |
+
@REM THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
| 15 |
+
@REM EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
| 16 |
+
@REM MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
| 17 |
+
@REM NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
| 18 |
+
@REM LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
| 19 |
+
@REM OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
| 20 |
+
@REM WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
| 21 |
+
|
| 22 |
+
python.exe -m pydoc %*
|
examples/libero/.venv/lib/python3.8/site-packages/_virtualenv.pth
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:69ac3d8f27e679c81b94ab30b3b56e9cd138219b1ba94a1fa3606d5a76a1433d
|
| 3 |
+
size 18
|
examples/libero/.venv/lib/python3.8/site-packages/_virtualenv.py
ADDED
|
@@ -0,0 +1,101 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""Patches that are applied at runtime to the virtual environment."""
|
| 2 |
+
|
| 3 |
+
import os
|
| 4 |
+
import sys
|
| 5 |
+
|
| 6 |
+
VIRTUALENV_PATCH_FILE = os.path.join(__file__)
|
| 7 |
+
|
| 8 |
+
|
| 9 |
+
def patch_dist(dist):
|
| 10 |
+
"""
|
| 11 |
+
Distutils allows user to configure some arguments via a configuration file:
|
| 12 |
+
https://docs.python.org/3.11/install/index.html#distutils-configuration-files.
|
| 13 |
+
|
| 14 |
+
Some of this arguments though don't make sense in context of the virtual environment files, let's fix them up.
|
| 15 |
+
""" # noqa: D205
|
| 16 |
+
# we cannot allow some install config as that would get packages installed outside of the virtual environment
|
| 17 |
+
old_parse_config_files = dist.Distribution.parse_config_files
|
| 18 |
+
|
| 19 |
+
def parse_config_files(self, *args, **kwargs):
|
| 20 |
+
result = old_parse_config_files(self, *args, **kwargs)
|
| 21 |
+
install = self.get_option_dict("install")
|
| 22 |
+
|
| 23 |
+
if "prefix" in install: # the prefix governs where to install the libraries
|
| 24 |
+
install["prefix"] = VIRTUALENV_PATCH_FILE, os.path.abspath(sys.prefix)
|
| 25 |
+
for base in ("purelib", "platlib", "headers", "scripts", "data"):
|
| 26 |
+
key = f"install_{base}"
|
| 27 |
+
if key in install: # do not allow global configs to hijack venv paths
|
| 28 |
+
install.pop(key, None)
|
| 29 |
+
return result
|
| 30 |
+
|
| 31 |
+
dist.Distribution.parse_config_files = parse_config_files
|
| 32 |
+
|
| 33 |
+
|
| 34 |
+
# Import hook that patches some modules to ignore configuration values that break package installation in case
|
| 35 |
+
# of virtual environments.
|
| 36 |
+
_DISTUTILS_PATCH = "distutils.dist", "setuptools.dist"
|
| 37 |
+
# https://docs.python.org/3/library/importlib.html#setting-up-an-importer
|
| 38 |
+
|
| 39 |
+
|
| 40 |
+
class _Finder:
|
| 41 |
+
"""A meta path finder that allows patching the imported distutils modules."""
|
| 42 |
+
|
| 43 |
+
fullname = None
|
| 44 |
+
|
| 45 |
+
# lock[0] is threading.Lock(), but initialized lazily to avoid importing threading very early at startup,
|
| 46 |
+
# because there are gevent-based applications that need to be first to import threading by themselves.
|
| 47 |
+
# See https://github.com/pypa/virtualenv/issues/1895 for details.
|
| 48 |
+
lock = [] # noqa: RUF012
|
| 49 |
+
|
| 50 |
+
def find_spec(self, fullname, path, target=None): # noqa: ARG002
|
| 51 |
+
if fullname in _DISTUTILS_PATCH and self.fullname is None:
|
| 52 |
+
# initialize lock[0] lazily
|
| 53 |
+
if len(self.lock) == 0:
|
| 54 |
+
import threading
|
| 55 |
+
|
| 56 |
+
lock = threading.Lock()
|
| 57 |
+
# there is possibility that two threads T1 and T2 are simultaneously running into find_spec,
|
| 58 |
+
# observing .lock as empty, and further going into hereby initialization. However due to the GIL,
|
| 59 |
+
# list.append() operation is atomic and this way only one of the threads will "win" to put the lock
|
| 60 |
+
# - that every thread will use - into .lock[0].
|
| 61 |
+
# https://docs.python.org/3/faq/library.html#what-kinds-of-global-value-mutation-are-thread-safe
|
| 62 |
+
self.lock.append(lock)
|
| 63 |
+
|
| 64 |
+
from functools import partial
|
| 65 |
+
from importlib.util import find_spec
|
| 66 |
+
|
| 67 |
+
with self.lock[0]:
|
| 68 |
+
self.fullname = fullname
|
| 69 |
+
try:
|
| 70 |
+
spec = find_spec(fullname, path)
|
| 71 |
+
if spec is not None:
|
| 72 |
+
# https://www.python.org/dev/peps/pep-0451/#how-loading-will-work
|
| 73 |
+
is_new_api = hasattr(spec.loader, "exec_module")
|
| 74 |
+
func_name = "exec_module" if is_new_api else "load_module"
|
| 75 |
+
old = getattr(spec.loader, func_name)
|
| 76 |
+
func = self.exec_module if is_new_api else self.load_module
|
| 77 |
+
if old is not func:
|
| 78 |
+
try: # noqa: SIM105
|
| 79 |
+
setattr(spec.loader, func_name, partial(func, old))
|
| 80 |
+
except AttributeError:
|
| 81 |
+
pass # C-Extension loaders are r/o such as zipimporter with <3.7
|
| 82 |
+
return spec
|
| 83 |
+
finally:
|
| 84 |
+
self.fullname = None
|
| 85 |
+
return None
|
| 86 |
+
|
| 87 |
+
@staticmethod
|
| 88 |
+
def exec_module(old, module):
|
| 89 |
+
old(module)
|
| 90 |
+
if module.__name__ in _DISTUTILS_PATCH:
|
| 91 |
+
patch_dist(module)
|
| 92 |
+
|
| 93 |
+
@staticmethod
|
| 94 |
+
def load_module(old, name):
|
| 95 |
+
module = old(name)
|
| 96 |
+
if module.__name__ in _DISTUTILS_PATCH:
|
| 97 |
+
patch_dist(module)
|
| 98 |
+
return module
|
| 99 |
+
|
| 100 |
+
|
| 101 |
+
sys.meta_path.insert(0, _Finder())
|
examples/libero/.venv/pyvenv.cfg
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
home = /home/Chris/.local/share/uv/python/cpython-3.8.20-linux-x86_64-gnu/bin
|
| 2 |
+
implementation = CPython
|
| 3 |
+
uv = 0.9.1
|
| 4 |
+
version_info = 3.8.20
|
| 5 |
+
include-system-site-packages = false
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:81a8736293366aeb5f916f86c52d5cd28ca81702edb09ddb5d4058f80a1978f3
|
| 3 |
+
size 7233650408
|