Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

python reference script directory

>>> import os
>>> print(os.path.dirname(os.path.realpath(__file__))) 
C:FileLocation # Does not contain filename
Comment

python how to get script directory

import os
print(os.path.abspath(''))
Comment

PREVIOUS NEXT
Code Example
Python :: mnist fashion dataset 
Python :: how to raise a error in python 
Python :: how to display equation in tkinter 
Python :: maximizar ventana tkinter python 
Python :: generate openai schema 
Python :: import file to colab 
Python :: python image read 
Python :: plot value counta 
Python :: link python3 to python3.7 
Python :: get all type of image in folder python 
Python :: bs4 from url 
Python :: python detect tty 
Python :: how to downgrade a package python 
Python :: How to subtract a day from a date? 
Python :: qpushbutton text alignment 
Python :: how to take user input in a list in python 
Python :: pygame python3.8 
Python :: iterative binary search python 
Python :: python return -1 
Python :: python get the elements between quotes in string 
Python :: ignore bad lines pandas 
Python :: print(DATA.popitem()) 
Python :: resample and replace with mean in python 
Python :: folium python map in full screen 
Python :: upgrade python to 3.9 i linux 
Python :: Pandas bins pd.cut() 
Python :: apple 
Python :: how to add numbers on top of bar graph in jupyter notebook 
Python :: how to get absolute path in python 
Python :: drop duplicates pandas first column 
ADD CONTENT
Topic
Content
Source link
Name
1+6 =