Community & Support
Learn
Marketplace
Discussions
Categories
Discussions
General
Platform
Academic
Partner
Regional
User Groups
Documentation
Events
Altair Exchange
Share or Download Projects
Resources
News & Instructions
Programs
YouTube
Employee Resources
This tab can be seen by employees only. Please do not share these resources externally.
Groups
Join a User Group
Support
Altair RISE
A program to recognize and reward our most engaged community members
Nominate Yourself Now!
Home
Discussions
Community Q&A
Import function from other Python file
green
I'm new to RapidMiner and I'm trying to use the Python Transfomer. I've been able to import libraries installed in my Anaconda environments. However, I want to import a function from another Python file (.py script) I have locally in my computer to be used in the Python Transformer. Is there any way I can do this?
Thanks in advance! Any help would be appreciated!
Find more posts tagged with
AI Studio
Python
Getting Started
Accepted answers
kayman
You can use sys to achieve this, then you just reference to the location of your script.
like :
import sys
sys.path.append('c:/some_folder/my_script')
All comments
kayman
You can use sys to achieve this, then you just reference to the location of your script.
like :
import sys
sys.path.append('c:/some_folder/my_script')
green
Works perfectly! Thank you so much!
Quick Links
All Categories
Recent Discussions
Activity
Unanswered
日本語 (Japanese)
한국어(Korean)
Groups