Python ImportError: No module named system [closed] - system

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 7 years ago.
Improve this question
import system module does not work in python2.7.3
Python 2.7.3 (default, Mar 13 2014, 11:03:55)
[GCC 4.7.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import system
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named system

If you wish for the sys module, try:
import sys
If you're looking for the system call, try:
import os.system

Related

Error while running burpsuite on my virtual machine [closed]

Closed. This question is not about programming or software development. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 6 days ago.
Improve this question
I typed $burpsuite in the kali Linux terminal and this is the error I get. I am new to Ethical Hacking and don't know how to solve the problem:
Error: A JNI error has occurred, please check your installation and try again
Exception in thread "main" java.lang.UnsupportedClassVersionError: burp/StartBurp has been compiled by a more recent version of the Java Runtime (class file version 61.0), this version of the Java Runtime only recognizes class file versions up to 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:756)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:473)
at java.net.URLClassLoader.access$100(URLClassLoader.java:74)
at java.net.URLClassLoader$1.run(URLClassLoader.java:369)
at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:352)
at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:601)
did you update your kali? can you type these commands:
sudo apt-get update -y. then, this : sudo apt-get upgrade -y

Dll load failed

My code is this, this is a test code from a youtuber:
import numpy as np
import cv2 as cv
from tensorflow.keras import datasets, layers, models
import mathplotlib.pyplot as plt
(training_images, training_labels), (testing_images,
testing_labels) = datasets.cifar10.load_data()
training_images, testing_images = training_images/255, training_labels/255
class_names = ['Plane', 'Car']
for i in range(16):
plt.subplot(4, 4, i+1)
plt.xticks([])
plt.yticks([])
plt.imshow(training_images[i], cmap=plt.cm.binary)
plt.xlabel(class_names[training_labels[i][0]])
plt.show()
And this is what happens when I run it:
Traceback (most recent call last):
File "C:\Python38\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 64, in <module>
from tensorflow.python._pywrap_tensorflow_internal import *
ImportError: DLL load failed while importing _pywrap_tensorflow_internal: A dynamic link library (DLL) initialization routine failed.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "image classification test.py", line 3, in <module>
from tensorflow.keras import datasets, layers, models
File "C:\Python38\lib\site-packages\tensorflow\__init__.py", line 41, in <module>
from tensorflow.python.tools import module_util as _module_util
File "C:\Python38\lib\site-packages\tensorflow\python\__init__.py", line 39, in <module>
from tensorflow.python import pywrap_tensorflow as _pywrap_tensorflow
File "C:\Python38\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 83, in <module>
raise ImportError(msg)
ImportError: Traceback (most recent call last):
File "C:\Python38\lib\site-packages\tensorflow\python\pywrap_tensorflow.py", line 64, in <module>
from tensorflow.python._pywrap_tensorflow_internal import *
ImportError: DLL load failed while importing _pywrap_tensorflow_internal: A dynamic link library (DLL) initialization routine failed.
Failed to load the native TensorFlow runtime.
See https://www.tensorflow.org/install/errors
for some common reasons and solutions. Include the entire stack trace
above this error message when asking for help.
I installed tensorflow from both anaconda and pip and same error happens, I cant seem to find a solution on this one so please help me out
The optimistic quick check, make sure you have the latest Visual C++ DLL installed.
I just encountered this myself; in my case the system I was trying to run Tensorflow on uses a G3220. According to Issue #39007 TensorFlow requires AVX extensions, which my CPU does not support. You can do a quick check to see if your processor supports AVX extensions by searching for it on the Intel Ark (Link to my G3220 which does not support AVX and a link to a i7-4790 that does support AVX. I suspect this is the same problem that you are having.
You may be able to compile TF yourself or use a build someone else made to run without AVX (see: Run TensorFlow 2.0 on CPU without AVX). In my case, I was able to use the unofficial TF python build referenced in this Stack Overflow answer to install TF 2.4 from here https://github.com/fo40225/tensorflow-windows-wheel.
Intel Ark i7-4790 AVX Example Image

Tensorflow - ImportError: DLL load failed: A dynamic link library (DLL) initialization routine failed

I am struggling to utilise TensorFlow within Jupyter notebook. I have installed TensorFlow via Anaconda Prompt (running as admin). But when I go to call it in my notebook I get the following error string (sorry this is long).
Any help or thoughts would be welcomed here - should I run a full uninstall and try again?
kind regards
Jack
I am running:
from tensorflow.keras.models import Sequential
from tensorflow.keras.layers import Dense
The error message is as follows (there are a number of others but this is the first and the rest have similar issue):
Traceback (most recent call last):
File "C:\Users\jjcon\Anaconda3\lib\site-packages\tensorflow_core\python\pywrap_tensorflow.py", line 58, in
from tensorflow.python.pywrap_tensorflow_internal import *
File "C:\Users\jjcon\Anaconda3\lib\site-packages\tensorflow_core\python\pywrap_tensorflow_internal.py", line 28, in
_pywrap_tensorflow_internal = swig_import_helper()
File "C:\Users\jjcon\Anaconda3\lib\site-packages\tensorflow_core\python\pywrap_tensorflow_internal.py", line 24, in swig_import_helper
_mod = imp.load_module('_pywrap_tensorflow_internal', fp, pathname, description)
File "C:\Users\jjcon\Anaconda3\lib\imp.py", line 242, in load_module
return load_dynamic(name, filename, file)
File "C:\Users\jjcon\Anaconda3\lib\imp.py", line 342, in load_dynamic
return _load(spec)
ImportError: DLL load failed: A dynamic link library (DLL) initialization routine failed.
During handling of the above exception, another exception occurred:
You have to install the Microsoft Visual C++ 2015-2019 Redistributable (x64) from here.
If you are facing any other issues possible reasons are
Your CPU does not support AVX2 instructions
Your CPU/Python is on 32 bits
There is a library that is in a different location/not installed on your system that cannot be loaded.
Please refer tested build configurations for windows CPU and GPU.

Selenium webdriver.Firefox() is not callable

I hope this is something simple, it feels like it. But it is beyond me at the moment.
I am a new starter with Selenium, I want to automatically extract information from a website and this seems a good method.
For a change I have started doing this on Windows 10 and I want program in Python so I am using PyCharm. I have installed Selenium using pip install selenium and if I use the python command line shell with the following:
from selenium import webdriver
driver = webdriver.Firefox()
I get the following error message:
Python 3.5.1 (v3.5.1:37a07cee5969, Dec 6 2015, 01:38:48) [MSC v.1900 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> from selenium import webdriver
>>> driver = webdriver.Firefox()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Users\Damo\AppData\Local\Programs\Python\Python35-32\lib\site-packages\selenium\webdriver\firefox\webdriver.py", line 81, in __init__
self.binary, timeout)
File "C:\Users\Damo\AppData\Local\Programs\Python\Python35-32\lib\site-packages\selenium\webdriver\firefox\extension_connection.py", line 51, in __init__
self.binary.launch_browser(self.profile, timeout=timeout)
File "C:\Users\Damo\AppData\Local\Programs\Python\Python35-32\lib\site-packages\selenium\webdriver\firefox\firefox_binary.py", line 68, in launch_browser
self._wait_until_connectable(timeout=timeout)
File "C:\Users\Damo\AppData\Local\Programs\Python\Python35-32\lib\site-packages\selenium\webdriver\firefox\firefox_binary.py", line 98, in _wait_until_connectable
raise WebDriverException("The browser appears to have exited "
selenium.common.exceptions.WebDriverException: Message: The browser appears to have exited before we could connect. If you specified a log_file in the FirefoxBinary constructor, check it for details.
When I type the same within PyCharm the IDE tells me that this term webdriver.Fiefox results in Firefox is not callable
Have I failed to install something?
>
Not meant as a silly reaction, but do you have the latest version of Firefox installed on your machine?

ImportError: No module named date_capnp

While trying to understand nupic minecraft demo code. I am running nupic_client.py from pycharm IDE. Python version is 2.7.8 on Mac OS with nupic dowloaded as package version 0.2.8
On running nupic_client.py following error occurs ImportError: No module named date_capnp
Any help is appreciated.
Stack Trace:
File "/Users/msghotra/Sandbox/CodeHub/datascience/workspace/nupic_minecraft/nupic_client.py", line 5, in <module>
from nupic.frameworks.opf.modelfactory import ModelFactory
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nupic/frameworks/opf/modelfactory.py", line 32, in <module>
from clamodel import CLAModel
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nupic/frameworks/opf/clamodel.py", line 44, in <module>
from nupic.encoders import MultiEncoder, DeltaEncoder
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nupic/encoders/__init__.py", line 24, in <module>
from date import DateEncoder
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/nupic/encoders/date.py", line 28, in <module>
from nupic.encoders.date_capnp import DateEncoderProto
ImportError: No module named date_capnp
I believe you mean nupic==0.2.3, since 0.2.8 isn't out yet. This should be fixed with https://github.com/numenta/nupic/pull/2231. More details are available in the issue you referenced (the direct link is https://github.com/numenta/nupic/issues/2166). Hope this helps!
EDIT This should now be resolved in nupic==0.2.6