module 'mmcv' has no attribute '__version__ - face-detection

I'm trying to use mmdet and mmcv in SCRFD for face detection and face this error:
mmcv_version = digit_version(mmcv.__version__)
AttributeError: module 'mmcv' has no attribute '__version__'
Has any buddy hit this error before?

I found the answer:
for torch 1.8 :
pip3 install mmcv-full==1.3.15 -f https://download.openmmlab.com/mmcv/dist/cu111/torch1.8.0/index.html
this command worked for me

For CPU Version :
pip3 install mmcv-full==1.3.17 -f https://download.openmmlab.com/mmcv/dist/cpu/torch1.8.0/index.html
This worked for me!

Related

opam init fails - unable to create temp file

I have installed opam 2.1.0 on a Linux Virtualbox VM. When I try opam init, I get the following error:
<><> Fetching repository information ><><><><><><><><><><><><><><><><><><><><><>
[ERROR] Could not update repository "default": OpamDownload.Download_fail(_, "Curl
failed: \"/snap/bin/curl --write-out %{http_code}\\\\n --retry 3
--retry-delay 2 --user-agent opam/2.1.0 -L -o
/tmp/opam-32196-d33843/index.tar.gz.part --
https://opam.ocaml.org/index.tar.gz\" exited with code 23")
[ERROR] Initial download of repository failed.
Running with --disable-sandboxing doesn't help. I know that its a problem creating/writing to /tmp/opam-... directory because if I replace that with my current directory or home directory the command by itself runs fine. It also runs fine with /tmp/opam-... if I use the --create-dirs option in curl but I don't have any way of getting opam init to use that option. Any ideas?
thanks
Update
The reason opam init failed for me was because curl was installed with snap on my system. This exactly what is going on with your VM.
Try to run opam init -verbose and that could reveal more about why you ran into an error.
In my case I needed to install other things with opam and it kept failing every time. So snap uninstall curl and then sudo apt install curl fixed things. (Was only able to figure this out with help from my professor)
Workaround
I ran into the same issue and I found a workaround on the OCaml forum: here. (Credits to UnixJunkie)
You can run:
opam init github git+https://github.com/ocaml/opam-repository.git
This should avoid the certificate issues. This worked for me.
I tried to fix the certificate issues using this answer as well. You could try doing that, but it seems complicated when the workaround is to simply point it to the github repo directly.
This question is similar to this one.

zsh: command not found: nx

I am trying to create a library in Angular using nx g #nrwl/angular:lib shared but it keep giving me error zsh: command not found: nx. All I did was before just create a angular project.
I try using this: npm install -g nx so maybe it install nx and it works, but I still keep getting the same error.
How can I fix this? I am using Mac.
If any questions or information needed please feel free to leave the comment down below.
sudo npm install -g nx fixed, sudo might be needed...
Try this: Install it globally by below command 100% will work
sudo npm i -g #nrwl/cli
remove -g if you don't want to install globally.
Either you don't have refreshed your zsh paths, which can be fixed by opening a new terminal or type
rehash
in the prompt.
If this doesn't work then nx isn't globally installed on your machine. You have to type
npm run nx [your command] instead of just "nx" to use it, so in your case:
npm run nx -- g #nrwl/angular:lib shared
Sources: https://nx.dev/latest/angular/cli/overview#installing-the-cli
Do we really need to install #nrwl/cli ?
Just installing the nx resolve the issue for me
sudo npm install -g nx#latest
Installing the nrwl cli globally should do the trick, you'll need to enter the super user mode to do it.
sudo npm i -g #nrwl/cli
Alternative solutions can be found on the guide on the Nx Website here
https://nx.dev/l/a/tutorial/01-create-application
Try this:
yarn global add #nrwl/cli

Not able to install sonar runner in Mac (Sierra)

I am trying to install sonar runner using below command.
brew install sonar-runner
Its giving me the error.
==> Searching for similarly named formulae...
Error: No similarly named formulae found.
Please suggest.
I think that sonnar-runner was replaced by sonar-scanner
brew install sonar-scanner

Installing typescript definition manager

Hi I am trying to install the typescript definition manager (TSD) on my Ubuntu 14.04 VM. I am following the '5 minute tutotial' from Angular.
It says to run
npm install -g tsd#^0.6.0
After that I am supposed to run
tsd install angular2 es6-promise rx rx-lite
Anyway, after running the last command Ubuntu simply returns
tsd: command not found
Can anyone help here?
Can you run the npm install -g tsd again, it should output the location where it installs it for you.
In this case that location isn't added to your path variable and you should use a absolute location (or add it to your path).
You should be able to do this in ubuntu by creating a ~/.profile file with
export PATH=$PATH:/path/to/tsd/folder/
The problem in my case seemed to be the nodejs version on my Ubuntu VM. I created a new VM and installed nodejs the following way
cd /usr/local/src
wget http://nodejs.org/dist/v0.12.7/node-v0.12.7.tar.gz
tar -xvzf node-v0.12.7.tar.gz
cd node-v0.12.7
./configure
make
sudo make install
which node
After this I could run
tsd install angular2 es6-promise rx rx-lite
and everything worked as expected. SO I believe updating the my nodejs was the solution. It seems that my old nodejs did not add tsd to the path
Can anyone help here?
Check your node version. Recommend you use latest iojs. It works as shown :

Error when install Trove Openstack Juno

I'm trying install Trove-Openstack Juno for Database service
I follow step by step in this doc http://docs.openstack.org/juno/install-guide/install/apt-debian/content/trove-install.html but i got an error message and i dont know how to resolve
apt-get install python-trove python-troveclient python-glanceclient \
trove-common trove-api trove-taskmanager
The following packages have unmet dependencies:
python-trove : Depends: python-sqlalchemy (< 0.9) but 0.9.7-1~cloud0 is to be installed
E: Unable to correct problems, you have held broken packages.
Please help me! Thank guys
Try this instead How To REALLY Install OpenStack Trove on Ubuntu 14.04

Resources