') + ')', 'gi'); if (regex.test(text)) { found = true; var frag = document.createDocumentFragment(); var parts = text.split(regex); parts.forEach(function(part, i) { if (i % 2 === 0) { frag.appendChild(document.createTextNode(part)); } else { var span = document.createElement('span'); span.className = 'userscript-highlight'; span.textContent = part; frag.appendChild(span); } }); node.parentNode.replaceChild(frag, node); } }); } else if (node.nodeType === 1 && node.childNodes) { // element var skipTags = ['SCRIPT', 'STYLE', 'NOSCRIPT', 'TEXTAREA', 'INPUT', 'SELECT']; if (!skipTags.includes(node.tagName)) { Array.from(node.childNodes).forEach(highlight); } } } highlight(document.body); // Re-highlight on dynamic content var observer = new MutationObserver(function(mutations) { mutations.forEach(function(m) { m.addedNodes.forEach(function(node) { if (node.nodeType === 1 || node.nodeType === 3) highlight(node); }); }); }); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:Highlight Search Terms]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + ', 'i'); if (__m === '*' || __re.test(location.href)) { // Strip utm_, fbclid, gclid, etc. from all links on page (function() { var trackingParams = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_term', 'utm_content', 'fbclid', 'gclid', 'dclid', 'msclkid', 'yclid', 'ref', 'ref_src', 'source', 'medium', 'campaign']; function cleanUrl(url) { try { var u = new URL(url, window.location.origin); var changed = false; trackingParams.forEach(function(p) { if (u.searchParams.has(p)) { u.searchParams.delete(p); changed = true; } }); return changed ? u.toString() : url; } catch (e) { return url; } } function cleanLinks() { document.querySelectorAll('a[href]').forEach(function(a) { var clean = cleanUrl(a.href); if (clean !== a.href) a.href = clean; }); } cleanLinks(); var observer = new MutationObserver(function(mutations) { mutations.forEach(function(m) { m.addedNodes.forEach(function(node) { if (node.nodeType === 1) { if (node.tagName === 'A') cleanLinks(); node.querySelectorAll('a[href]').forEach(function(a) { var clean = cleanUrl(a.href); if (clean !== a.href) a.href = clean; }); } }); }); }); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:Remove Tracking Parameters from Links]', __e); } })(); (function(){ try { var __m = "youtube.com"; var __re = new RegExp('^' + "youtube\\.com" + ', 'i'); if (__m === '*' || __re.test(location.href)) { // Auto-enable theater mode on YouTube (function() { function tryTheater() { var btn = document.querySelector('button[aria-label="Theater mode"], ytd-player #player button[title="Theater mode"]'); if (btn && !btn.classList.contains('activated')) { btn.click(); } } // Try immediately tryTheater(); // Try after navigation (SPA) var lastUrl = location.href; setInterval(function() { if (location.href !== lastUrl) { lastUrl = location.href; setTimeout(tryTheater, 500); } }, 1000); // Also try on player load var observer = new MutationObserver(tryTheater); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:YouTube Theater Mode Default]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + ', 'i'); if (__m === '*' || __re.test(location.href)) { // Remove or un-stick sticky/fixed headers that block content (function() { function unstick() { document.querySelectorAll('header, nav, [role="banner"], .header, .navbar, .sticky, .fixed-top, [style*="position: fixed"], [style*="position:sticky"]').forEach(function(el) { if (el.style.position === 'fixed' || el.style.position === 'sticky' || getComputedStyle(el).position === 'fixed' || getComputedStyle(el).position === 'sticky') { el.style.position = 'static'; el.style.top = 'auto'; el.style.zIndex = 'auto'; } }); } unstick(); var observer = new MutationObserver(unstick); observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ['style', 'class'] }); })(); } } catch(__e) { console.warn('[Userscript:Kill Sticky Headers]', __e); } })(); })(); [Solved] Something went wrong in `get_repo` & Aim up don't work well · Issue #8 · polixir/OfflineRL · GitHub
Skip to content

[Solved] Something went wrong in get_repo & Aim up don't work well #8

Description

@Dilettante258
$ python examples/train_task.py --algo_name=cql --exp_name=halfcheetah --task HalfCheetah-v3 --task_data_type low --task_train_num 100
2023-11-03 at 16:35:56.112 | INFO | Use cql algorithm!
running build_ext
2023-11-03 at 16:35:56.618 | INFO | obs shape: (1000, 18)
......
......
2023-11-03 at 16:35:56.870 | INFO | Init AlgoTrainer
Something went wrong in`get_repo`. The process will continue to execute.
`get_repo`: branch name must be at least 2 characters and contain only latin letters, numbers, dash and underscore
Something went wrong in`__init__`. The process will continue to execute.
`__init__`: 'NoneType' object has no attribute 'path'
Something went wrong in`track`. The process will continue to execute.
`track`: session is closed

I tried to follow the steup requirements ("aim==2.0.27"), but some nuisance still happened.

After investigation, the error was located on line 306 of the Session class in the aim up module.

Amend the file "/home/username/anaconda3/envs/env_name/lib/python3.8/site-packages/aim/sdk/session/session.py"

ifpathisnotNone:
repo=AimRepo(path)
ifnotrepo.exists():
ifnotrepo.init():
raiseValueError('can not create repo `{}`'.format(path))
repo=AimRepo(path, branch_name, commit_hash)

Replace the second line of the above code with repo=AimRepo (path, branchname, commit_hash)(or delete it), but it still don't work very well.

After about 6 hours of tortuous process😵, I finally get a hapharzcan env which works well.🥳

The following table shows some versions of libraries that I think are worth emphasizing.

NameVersion
python3.8.18
cython0.29
setuptools63.2.0
pysqlite30.5.2
pip23.3.1
ray1.12.0
aim2.3.0
fire0.3.0
glfw2.6.2
numpy1.20.3
protobuf3.19.0
torch2.1.0
scikit-learn1.3.2
mujoco-py1.50.1.0
swig4.1.1
gym0.19.0

The following table is the environment profile after I deleted some unimportant libraries for your reference. 🤝I hope it can be helpful to you!

#NameVersion
_libgcc_mutex0.1
_openmp_mutex5.1
absl-py2.0.0
aim2.3.0
aimrecords0.0.7
aimrocks0.0.7
aiofiles23.2.1
aiohttp3.7.4
aiohttp-cors0.7.0
aioredis1.3.1
aiosignal1.3.1
asttokens2.4.1
async-exit-stack1.0.1
async-generator1.10
async-timeout3.0.1
atari-py0.2.6
attrdict2.0.1
attrs23.1.0
box2d-py2.3.5
cython0.29
decorator4.4.2
deprecated1.2.14
distlib0.3.7
dm-tree0.1.8
docker6.1.3
filelock3.13.1
fire0.3.0
flask1.1.2
glfw2.6.2
google-api-core2.12.0
google-auth1.35.0
google-auth-oauthlib0.4.6
googleapis-common-protos1.61.0
gtimer1.0.0b5
gunicorn20.1.0
gym0.19.0
gym-notices0.0.8
libgcc-ng11.2.0
libgomp11.2.0
libstdcxx-ng11.2.0
lockfile0.12.2
mujoco-py1.50.1.0
multidict6.0.4
neorl0.3.1
networkx3.1
numpy1.20.3
numpydoc1.6.0
oauthlib3.2.2
offlinerl0.0.1
opencensus0.11.3
opencv-python4.8.1.78
openssl3.0.11
pandas2.0.3
parso0.8.3
pexpect4.8.0
pickleshare0.7.5
pillow10.0.1
pip23.3.1
protobuf3.19.0
pyasn10.5.0
pyasn1-modules0.3.0
pycparser2.21
pydantic1.10.13
pygame2.1.0
pyglet2.0.9
pygments2.16.1
pyopengl3.1.7
pyopengl-accelerate3.1.7
pyparsing3.1.1
pyrser0.2.0
pysqlite30.5.2
python3.8.18
ray1.12.0
readline8.2
redis4.1.4
rsa4.9
scikit-learn1.3.2
scipy1.10.1
setuptools63.2.0
sphinx7.1.2
sqlalchemy1.4.13
sqlite3.41.2
stack-data0.6.3
starlette0.14.2
swig4.1.1
sympy1.12
tabulate0.9.0
tensorboard2.3.0
tensorboardx2.6.2.2
termcolor2.3.0
threadpoolctl3.2.0
tk8.6.12
tomli2.0.1
torch2.1.0
tqdm4.66.1
urllib32.0.7

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions