Skip to content

AliSerwat/PyTorch-DeepLearning-EasySetup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 

Repository files navigation

Welcome to My AI Learning Repo! 🌟🚀 Open in Studio

📚 If you're new to AI and eager to learn, PyTorch is an excellent library to start with. For beginners, "Deep Learning for Coders with Fastai and PyTorch, 1st Edition", along with the Practical Deep Learning for Coders YouTube playlist and its website, provide a basic introduction to AI topics.

⚙️ While Fastai simplifies PyTorch for newbies, it may not be suited for real-world projects due to maintenance problems between versions 1 and 2.

🖥️ To create an efficient environment for practicing the content of "Deep Learning with PyTorch, 1st Edition", consider utilizing a remote server. This technique avoids the complications of local machine setup and potential package conflicts, which are typical in resource-intensive activities like deep learning algorithms.

📦 The second part of the book entails downloading 66.7 gigabytes of data (Luna16 Dataset), which requires around 220 gigabytes of storage for manipulating medical images.

🔧 To solve these obstacles, lightning.ai offers free remote servers with suitable processing power and storage. lightning.ai prevents the establishment of new Conda environments within their studios, however Docker containers give a rapid alternative to this issue.

🔍 During my study on the PyTorch medical imaging project, "Docker: Up & Running: Shipping Reliable Containers in Production, 3rd Edition" proved vital. Docker's isolation feature allows you to treat running containers as full OS environments, easing the installation and upgrading of programs and libraries.

For getting started

  1. Click on the badge (you need to create an account in lightning.ai).
  2. Clone my repository:
git clone https://github.com/AliSerwat/PyTorch-DeepLearning-EasySetup.git
  1. Change create_docker_image.sh's mode:
chmod +x ~/PyTorch-DeepLearning-EasySetup/create_docker_image.sh
  1. Execute create_docker_image.sh:
~/PyTorch-DeepLearning-EasySetup/create_docker_image.sh

After Creating and Executing the Container, something like this should be displayed in your terminal

(base) root@aeee2fcb741b:~#
  1. Activate pytorch_env environment:
conda activate pytorch_env

It must look something like this:

(pytorch_env) root@aeee2fcb741b:~#
  1. Clone Deep Learning with PyTorch repository:
git clone https://github.com/deep-learning-with-pytorch/dlwpt-code.git
  1. Fix a minor issue in ~/dlwpt-code/util/disk.py:

    1. Open the file in your editor:

      code ~/dlwpt-code/util/disk.py
    2. Replace the following lines:

      import gzip
      
      from diskcache import FanoutCache, Disk
      from diskcache.core import BytesType, MODE_BINARY, BytesIO
      
      from util.logconf import logging
      log = logging.getLogger(__name__)
      # log.setLevel(logging.WARN)
      log.setLevel(logging.INFO)
      # log.setLevel(logging.DEBUG)

      with:

      from util.logconf import logging
      import io
      import gzip
      
      from diskcache import FanoutCache, Disk
      # delete BytesType and BytesIO declarations
      from diskcache.core import MODE_BINARY
      
      BytesType = bytes  # Import them by ourselves
      BytesIO = io.BytesIO
      
      log = logging.getLogger(__name__)
      # log.setLevel(logging.WARN)
      log.setLevel(logging.INFO)
      # log.setLevel(logging.DEBUG)
    
    

Overcoming Internet Connectivity Restrictions in Iran 🌐🔓

Due to internet connectivity restrictions in Iran, including filtering and sanctions, I want to share how to overcome these challenges.

⚡ AI has brought tremendous potential to our lives, requiring minimal resources compared to other emerging fields. However, conducting original research projects can be challenging due to budget and resource scarcity in many fields.

Since the infrastructure for AI development is accessible remotely and freely, I want to emphasize this opportunity. It allows your talents and potential to flourish despite circumstances beyond your control, such as where you were born.

All you need is a PC, a stable, unlimited internet connection, and a phone number for verification

  1. 🌍 VPN for accessing unlimited connection: Purchase VPN plans tailored to your needs from this Telegram bot, which offers helpful tutorials (I typically use a Great Britain IP address to bypass restrictions).
  2. 📞 Purchase a single-use virtual phone number from numberland.ir. I bought an inexpensive England number to verify my lightning.ai account. ⚠️ Ensure your VPN's IP address and the number's origin country match to avoid discrepancies.

PS: You can also use numberland.ir's numbers to verify your Kaggle account

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published